From nczonline.net, with love.
View this email in your browser

jQuery Today

Hi everyone,

Not too long ago, Lea Verou wrote an article entitled, jQuery considered harmful, in which she argued that you're better off not using jQuery anymore for a number of reasons. Lea's hypothesis is that jQuery's cost (library size, extra objects, perceived complexity) outweigh its benefits when you're not dealing with older browsers. I found myself disagreeing with this hypothesis rather adamantly as I read the article.

Lea's assertion is that you can just use native JavaScript APIs if you are only dealing with modern browsers, and that's something I would never recommend. As soon as you leave an abstraction behind, you end up putting developers in a spot where they must now know which browsers support which APIs and what cross-browser quirks (if any) exist. That extra cognitive load can't be discounted, as not realizing browser A didn't work exactly the same as browser B can easily lead to hard-to-find bugs. I even wrote a free ebook about why avoiding native JavaScript APIs is often the best course of action.

I maintain that there's a place for jQuery in today's JavaScript toolkit, but that place is lower in the stack than it has traditionally been used. jQuery is an excellent browser-normalization library, something that every web application needs to survive. Sure, you could roll your own, but then you'd just be rediscovering all of the cross-browser incompatibilities and bugs that jQuery already covers. Maybe you're interested in doing just that, but not me. I'd rather get to work coding up compelling user experiences and I don't want engineers on my team spending all of their time trying to track down browser differences.

So if you're using jQuery already, I'd advise you not to rush to remove it. Perhaps push it further down the stack so people are mostly using regular DOM objects, and delegate lower-level functionality to jQuery via some further abstraction. jQuery is absolutely not harmful and still has a very important role to play in today's web applications.

Be well.

-N
JavaScript WeeklySponsor: Microsoft Edge
We're building Microsoft Edge in the open. View our roadmap.

Recommended Links

Russia's Wikipedia ban buckles under HTTPS encryption (article)
Wikipedia's decision to switch to HTTPS had repercussions in Russia, a country that blocks certain Wikipedia pages. Switching to HTTPS meant that Russian authorities could no longer determine which pages were being requested and therefore couldn't figure out which ones to block...so they blocked them all. The outcry forced Russia to take a backstep, showing just how powerful HTTPS really is.

How your smartphone's battery life can be used to invade your privacy (article)
The Battery API allows web applications to determine the battery status of the device in which the application runs. The idea is to allow web application developers to switch to "low power" modes for better performance. However, researchers have discovered that battery states can function as unique identifiers and may have privacy implications for users.

Mobile-friendly web pages using app banners (article)
We've all had the experience of going to website on a mobile device only to be met with an interstitial reminding us that they have an app. Google now considers this to be mobile-unfriendly and will penalize these sites in search results by removing the "Mobile Friendly" tag. It's hoped that this move will encourage more sites to move to app banners and less obtrusive ways of encouraging app downloads.
JavaScript WeeklySponsor: O'Reilly Media
Get 50% off JavaScript titles and more during our Famous Back-to-School Tech Sale

Recommended Book

Creativity, Inc. is the story of how Pixar was created and the management style employed by cofounder Ed Catmull. If you've ever worked on a growing team, as an engineer or a manager, you'll appreciate the thoughtfulness and candor with which Catmull recounts his mistakes, frustrations, and realizations while guiding a wildly successful company from its infancy into an internationally-recognized studio. He also offers a behind-the-scenes look at Steve Jobs' influence on the company and on Catmull himself. If you're interested in moving into leadership, or are already there and looking to improve, this book is a must-read.

Recently on NCZOnline

My favorite interview question
Interviewing and hiring are more difficult tasks than they may seem. The cost of hiring the wrong person is quite high, yet companies that are hiring often want help sooner rather than later and so sometimes don't want to wait for a good candidate to come along. I operate on the mindset that the damage...

Is the web platform getting too big?
Peter-Paul Koch recently wrote a blog post entitled, "Stop pushing the web forward" [1], in which he argued for a one-year moratorium on adding new features to the web platform. By new features, he means new APIs and capabilities in HTML, CSS, and JavaScript, arguing: We're pushing the web forward to emulate native more and...

From Wordpress to Jekyll: My new blog setup
I had been thinking about moving my blog from Wordpress to Jekyll for a while. I was hesitant because I didn't know a lot about how Jekyll worked and wasn't sure if I'd ultimately want to have my site hosted on GitHub or not. I also was concern about not having the ability to schedule...

Feedback

Love this newsletter? Hate it? Have suggestions for how to make it better? When you subscribe to the newsletter, you can just reply to send in feedback.
Copyright © 2015 Nicholas C. Zakas, All rights reserved.


unsubscribe from this list    update subscription preferences