As I was doing my morning reading, I came across this very insightful article on A List Apart. The argument is as it always goes. You should use jQuery only when appropriate. More specifically:
I agree with almost everything he says in this post, but I draw the line elsewhere. The main concern on whether to include or forego jQuery in your project comes down to website speed, and whether you need to load the 96KB (not a small number) required to load the current minified version of jQuery. There are other advantages/disadvantages, like having to worry about noConflict mode if you’re using other libraries, but you get the point. This is where I draw the line. If your small- to medium-sized library gets larger than a minified version of jQuery, then you’re not doing yourself any favors.
Another way to look at this issue: people who make websites normally have a “server budget” that they use in order to optimize their website speed. You can make the conscious decision to include those 96KB of jQuery code in that budget, and not have to worry about the time you’ll spend writing the code to match what jQuery does out of the box. But, as Anthony says in his post, that decision is up to you in the end. Do whatever is best for your project.
In the comments, something else caught my eye:
Honestly, I really wish there were more people that can write Vanilla JS (I like how we’re now using the term like it’s a library—what, no version number?). There are far too many people out there that can ONLY write things using jQuery. The number of HTML5 polyfills I have seen that require jQuery is just plain sad. If I’m including a polyfill I want something light that just does the job. I don’t want to have to include jQuery as well just to get the job done.