DEV Community

Discussion on: Who still regularly uses jQuery?

Collapse
 
thebouv profile image
Anthony Bouvier

Yup.

Cause not all of us over-engineer things by applying React or Angular to every bespoke 4 page website.

We have clients that are restaurants, bookstores, ad agencies, and otherwise and if you build out a 10 page website for any of those and decide setting up a complex frontend build system somehow makes sense for them, boo on you.

BootStrap 4 is super popular (and v3 still actually). It includes jQuery.

WordPress powers an insane # of websites and jQuery is included by default.

I've said it here many times in comments: you better have a great reason for choosing one of those frameworks. Otherwise, you're over-engineering and making a poor choice.

There are more websites/webapps that don't need those than there are that do need them.

Collapse
 
alangdm profile image
Alan Dávalos

I would agree that if anything the point of removing JQuery is because you can do most of that stuff with just vanilla JS, not that you need to begin using a framework

As you mention, using a JS framework for every static 4 page site is overkill, but adding a 30kB library when you can make without it is still plenty overkill IMO

There's a good reason why Bootstrap 5 is ditching JQuery 5 and just using plain old JS ;)

Collapse
 
skydevht profile image
Holy-Elie Scaïde

Yeah, but jQuery and the like are very readable and consistent. Sometimes, jQuery may be too heavy, that's why I used a smaller framework for dom manipulation. But if it's there or there's no bandwidth issue, jquery it is.

Collapse
 
thebouv profile image
Anthony Bouvier

I do agree with you on removing jQuery to replace things with vanilla js. I'll never argue against that unless you still have to support IE11 (and I happen to need to because on some sites I deal with I still get upwards of 10% of my visitors coming from IE11).

But: 30kb, what ever will we do in comparison to what gets downloaded with React/Vue/Angular and whatever monstrous sized files webpack creates?

Yet the state of front end dev right now will download 100+kb in fonts and let's not even talk about the image size people put out right now.

Or the friggin' ad network includes, trackers, analytics, etc.

There are a dozen other things to fix first in optimizing front end web page total download size than a single library. The average web page size in 2010 was 702kb compared to in 2016 which is 2232kb.

jQuery's size is hardly the problem. :)