jQuery was the dominant library in front end web development not too long ago.
The industry has largely moved on from jQuery for greenfield projects, but I’m sure plenty of folks are still maintaining jQuery projects.
So I’m curious to hear about your use cases and plans for the future.
Assuming that people doing jQuery are maintaining legacy code is not necessarily right.
In my company, there is no people trained on modern front-end ecosystem (and they do not want to learn), and the only thing they know is a bit of jQuery. More than this, the main proprietary business tool they use (a survey program for online surveys) makes an extensive use of jQuery.
Being the only developer in the team I had to think what to do when they asked me to develop a new module for this tool. I did integration tests with React and the result was bad: the host tool is fully based on jQuery and it's DOM is based on a visible layer plus an invisible layer, what makes impossible to integrate, for example a React virtual DOM in it without messing up badly with the whole thing and write awful code.
After considering this, I decided to use jQuery and I am happy with it. I integrated it with a simple client side templating system and some other modern tools (transpiling, etc.) and I think we delivered a very strong product.
Depending of the situation jQuery can still be the good choice and I actually think that in some situations, choosing tools that are not adapted to your use case only because they are the de facto trendy ones can be harmful.
By the way, I tend to think that jQuery still is the dominant front end library in use (I have no source for this assumption though). People who say « it is sad [they] still have to use jQuery» in their legacy project makes a mistake because if you use jQuery in a modern way, it is totally possible to create some maintainable code, refactor old code using modern practices and make your life easier.
Remember jQuery is only a tool among other and that the new tools like Vue, React and Angular benefit of a powerful hype those days that tends to make us think that old tools are not good anymore: but those are only tools. It's still up to you to do something good or bad with them.
Why I'm still using jQuery in 2019
I wholeheartedly agree with your post.
Actually, some people who have seen the code for my jQuery project expected a mess of spaghetti code, which is not at all!
I told them spaghetti code is not framework exclusive, nor a jQuery requirement.
It's bad programming practice, and it can happen on any and every framework.
I created super tasty spaghettis using React by the way!
What are some things jQuery is good for -that you can't already do with vanilla Js?
What implementation of "vanilla JS"?
I don't actually work with these things, but I did learn that when you're supporting browsers back to IE 6, jquery is very handy.
JQuery is excellent at browser compatibility: you just use it's simple-short-to-write functional syntax and it runs everywhere.
Doesn't it remind nicely the JVM?
Writing modern js is easy to get full compatability with babel or polyfills
Do you call Babel and Polyfills « Vanilla JavaScript » ? It's already JavaScript with super-powers.
There are people who do jQuery and who doesn't know how to set up those kind of environments. And their company don't want them to learn and/or they aren't interested to go further on their own.
I don't say it is good, and it should surely be avoided, but the simplicity of use of jQuery is for sure a great plus. Overusing it at a certain point for complex applications today is surely a mistake and the tools you mentioned should be used in most of the cases.
Is it though? When do you pull in a polyfill? Is it for every JS feature you use? Did you remember to check the compatibility guide?
Im not saying you want to go without testing, but testing is all about figuring out what is not needed to be tested.
Yeah, my current project is on the bleeding edge of technology!
I'm in the exact same boat, but learning MERN stack for future employment possibilities.
Yes! I'm currently the one who's rewriting a 10-year old front-end codebase in favor of vanilla JS. It has come a long way and now is mostly only being used as AJAX wrapper and a Bootstrap 3 dependency.
Every day I'm getting closer to removing this one line from the core module.
Me, I'm still using it as we speaking.
Why? I haven't learned about React or Vue (which I will do in the future). But currently I'm making a web app like reddit.
I want to finish the MVP soon enough, so I will just use what I know at the moment which are Laravel and jQuery.
I don't care if someone will call me old-fashioned developer just because I'm still using jQuery.
And btw, @ben , I've sent you my request through Private Message
There are dozens of us! I promise!
I still actively CHOOSE to use jQuery. Yes it's a dependency, but I find jQuery a lot easier to read and code in than vanilla JS.
same here buddy! things need to get done so I have to use what I know... I'd love to take my latest jQuery project and turn it into React and Vue... and even web components to see what all the hoopla is. just need the time :(
The JS world is buggy, confusing and pathetic with the astronomical number of NPM packages that do more or less the same thing, or the N number of different patterns used to implement the same thing (like object creation or manipulating an array or collection).
And the unfortunate thing is that whenever a popular library or package tries to move towards standardization (jquery, for example), devs seem to be all pitchforks about it! I don't really get all the fury against jquery. Its just a neat library for DOM manipulation, use it if you like, don't otherwise!
I did a quick project with jQuery a tad over a year ago!
Haven't touched it again (it's been working fine, no bugs anymore) but I enjoyed it.
Right after that, I started working with Vue and Nuxt exclusively, and I like it way more!
So much cleaner and easier to manage, especially with Vuex.
I tried React as well but I enjoy Vue much more.
Yeah man, we still use it.
I've said it here before and I'll say it again:
React, Vue, and Angular are fine tools. But if you try to apply it to every damn website you work on, you're over-engineering plain and simple.
Though the loudest devs online are all about SPAs and heavy front end frameworks, there's also a ton more out there building 20 page brochure-ware websites for companies. And at most they want to manipulate the DOM a little bit, do some AJAX calls simply, and maybe some nice form validation.
If they introduced React and it's whole build system into a project like that, they'd blow the budget easily.
Don't write crap code, and jQuery-based websites are not hard to maintain. Too many zealots out there would have you think that choosing jQuery is always horrendous, but they live in a different world. Not all of us are working on SaaS products, SPAs, and re-inventing the next Twitter. We have restaurant websites, ad agency sites, and more to take care of.
Couldn't agree more.
Why woudl i use some SPA framework if i just need to use javascript for some popup, carousel and AJAX contact form?
According to some official statistics, currently over 70% of all websites use JQuery and it has become an unofficial web standard for DOM manipulation. Other JavaScript Frameworks such as Angular and REACT are popular but unsustainable because they have too many code-breaking iterations.
As an Senior Web Engineer, theres almost NOTHING that I can't do with Web Standards such as HTML/CSS/JQUERY that REACT and VUE and ANGULAR can do.
I speak for other developers who REFUSE to learn the next shiney framwork; stop forcing your web engineering preferences on us. We are perfectly efficienct and content in engineering web experiences for our Fortune 500 clients using simple easy web standards without the need to over complicate it with stacks of plugins and frameworks.
Well thankfully not anymore!
I was maintaining a jQuery dependent CMS for my last employer, but kept pushing for a migration to Vue.js throughout last year until it finally worked... I was able to sleep better at night :D
I recently started using fomantic-ui.com/ and use jQuery with that all the time now. I didn't for quite a while and rolled completely custom, since I don't use React, Angular, Vue, etc. But switching to Fomantic feels like a nice breath of fresh air at the moment.
That is until the next CSS library uses Custom Elements and it'll be great. I'm still salty they got rid of
link[rel=import]
The flagship product of the company I worked for until a few weeks ago is still rolling jQuery, and it doesn't look like that would change in the next 3 years. It's a too big of a monolith application to just change.
And I would still use it on a daily basis if I wouldn't have quit the job.
Im part of a team which is rebuilding a huge cms for big portals at work. The js parts are entirely built with jquery. We are rebuilding to change the entire archtecture, and we are using vue to front. But new features still come to the old one and, yes, they're implemented with jquery :)
Unfortunately, I am.
Actually, you can still use jQuery. This isn’t a problem. But the problem of all codes is legacy.
When I started working, I realized a 20k lines of codes.
I’m still afraid of edit it. It kind of DO NOT EDIT section for me.
Occasionally, I work on marketing sites with dynamic content. Just about every theme out there is going to have jQuery already, and it's simple to use.
I know you can do just about anything it can do with vanillaJS, but still I'd rather write
$('#login-form').click(doSomething)
over
document.getElementbyId('#login-form').addEventListener('click',doSomething)
And just this morning, I was debating whether an internal page with an AJAX form should be a bit of jQuery or a React component. I could make a case for each.
I am even creating new projects on jQuery because it gives me more flexibility that others have not demonstrated. I have been eying vue though, but looking for a way to do common stuff like modal, datatables, datetime etc. Because I haven't seen it as easy as jquery libraries, I ignored.
I just newly started as the frontend guy on a team that has been around for about 3 years, and jQuery is their previous standard.
While I will not use jQuery (at least, I cannot imagine a need for it), I also will not refactor, because Chesterton's Fence.
On my list of reforms are: continuous integration, TDD, and code reviews, among others.
Super, super nice people and great clients, so whatever I do, that culture must be preserved above all.
DEV is :P
from github.com/thepracticaldev/dev.to/...
My plan for the future is to switch to ActiveStorage :D
It's probably fine for simple projects, but even simple projects tend to evolve into projects that require discipline. So for work-related projects, I run like the plague from any programming that's imperative, like JQuery's API. Declarative programming (like ReactJS) fits so much more with my personal beliefs: "It is what it is."
JQuery is more like "But no. Be this instead!"
Using jQuery on my current project just because Materialize-css' materialbox is not at the level of LightGallery.js (sachinchoolur.github.io/lightGallery/).
Without it, no jQuery, only vuejs 😊
Most of our legacy work depends on jQuery and it's plugins. But whenever I have to create a new feature, I write it with vanilla JavaScript. But I look for ways to build new projects with modern frameworks when I can.
Yes , me ... :P
you are totally correct, but here in india many companies still using jquery!
i am working on JSF and primefaces which is heavily depend on jquery and jquery ui.
interesting part is the project i am working is approx less than 2 yrs old.
well, future plan would be stick to the primefaces i guess.
NOTE : For my personal projects i would prefer reactjs.
Happy coding :)
In other news while ikea loves allen key screws and bolts in their popular preset furniture, private craftsmen may sometimes enjoy using philips head and even flathead bolts if they are the correct sizing and thread.
Jquery is a phillips head bolt. If you only make ikea furniture then stick to your allen keys: react angular etc. i still have many phillips heads and bits for my tools and drills...
Build as you like...
Did a project recently with Google Sheets API and Random User API and Google Scripts that I tried for the first time and I can't stand now 🤣 . So basically there are few input forms and a button for getting the random user to be shown in the input and then submitted to the google sheets
I've mostly moved over to vanilla JS for my DOM manipulation (I've dabbled in modern frameworks, but nothing major).
Doing AJAX requests is something I MIGHT still reach for jQuery on. I feel like the native JS method for this is a little clunky, but I also don't do that too much day-to-day.
I'm still working in JQuery. I think it really depends on your project. For those developers who are maintaining projects that are over 5 or even 10 years old, and have not migrated to newer ones, JQuery is still very much in use. Also, smaller lighter projects that do not require frameworks like Angular or Vue, i.e, small sites, are probably utilizing JQuery. I find that big retail sites are often using them as well, and it really depends on the culture of the organization.
I still use jQuery extensively. We build our services using Django/Flask. And provide our users (B2B) with an administrative UI based on Bootstrap. I'm not a fan of a SPA's it creates a set of problems which I am aware solutions for are available. Currently each page is rendered by the server. jQuery and little bit of vanilla JS does the job pretty well. I couldn't find a problem with our implementation.
Although, we do build Standalone Angular services for some of our clients for their customers (B2B2C) in some cases.
I do understand the advantages of using a modern JavaScript Library or a framework "or at least I think I do" yet I don't see that we face any of those problems to make the transition.
I still find JQuery useful for the most basic interactive functionality, like showing/hiding a section of the page on click, because I can get it set up without needing any boilerplate whatsoever.
But I really should start to use the approach of the following article, of just mapping my most-common JQuery APIs to the native browser functionality
Use $ & $$ Instead of document.querySelector/All in JavaScript without jQuery
Ahmad Awais ⚡️ ・ 1 min read
I use jQuery and pure javascript both, depending on project and need.
I'd never recommend using React or Vue or any other library that tries to arm-wrestle open web standards. React is fancy, no doubt, but the aim of these corporation backed projects is to hurt and stifle making of the web standards. Call it names and displace: simplicity, accessibility and openness of the web with a view that supports a closed garden of their own.
Also, React/Vue projects are terrible at accessibility, maintainability and are expensive to maintain.
I work at a small company that still uses Bootstrap + jQuery, because it works with solutions that have been built a while ago so making big changes would be a big job.
Personally I don't think it's much of a big deal.
Just because it's not necessarily needed, doesn't mean using it hurts.
Our public website uses Bootstrap, so I'm using it until we get around to redesigning the site. Using jQuery and Webpack together feels odd, though.
The site was originally built on Rails 5.0, just before they dropped the jQuery dependency in 5.1.
For our employee dashboard I use StimulusJS, which is great for the minimal dynamic features that we need. I'll probably use it for the public site as well whenever we redesign it.
Still using it on any WordPress website projects. Because it supported by default.
So to make simple AJAX request, manipulate DOM still using it on WordPress website.
We still use it in some older projects (that are in maintenance), but here is an excerpt I wrote in one of our newer projects (React):
Our newest project has jQuery on a part on Chrome extension.
Basically the selector engine inside jQuery is more versatile than native query and css selector needed for the project.
"You don't need jQuery?", you do.
Moreover, the library we need has a dependency for jQuery, and we can neither find any alternative nor has time to recreate it since rebuilding it will take several months.
We cannot waste several months just for sake of one part of a 20 part project.
Oh, one part uses jQuery, another React, on same page. Just not the way you would imagine.
Me! My main project is a 5ish year old Rails app and it's pretty heavily dependent on jQuery, both through our own code and third party widgets.
I wouldn't start a new project with jQuery, but there's no strong incentive at the moment for us to re-write a mammoth code base. I've dabbled with sort of "phasing in" Vue or React, but that never really took off with the rest of the team.
It'll do. For the next two weeks, anyway, and then I'm starting a new role elsewhere, so it won't be my problem any more. 😅
I have few jQuery plugins that I'm maintain. And at work we use R language framework, called shiny, that use jQuery. It's event based framework and most of the work is done in Front-End like R Back-End (except JS and CSS, HTML is mostly on Back-End). But all additional widgets that you create and all JS code need to be written in jQuery. There are no other framework in R for Web Apps.
For my personal projects I may use architecture Framework/Library but you can quickly create simple prototype just using jQuery. It's easier to create this on Codpen than Angular application.
We are using jQuery. Our company love it because of its cross-platform feature, where you don't have to worry that much anymore, while writing your source code.
Addition, there are still CMS platforms, use jQuery. Example, this CS Cart that we are working in our current project.
I do. jQuery for life.
It is one of the easier ways to start working with DOM manipulation.
I've chose to use jQuery because of team constraints (me the only dev), money and time.
React or other SPA frameworks might be better but limitations make it not possible to work with them even when React would make the job easier at sometime.
Also, working a lot of time with jQuery have made me realize what SPA libraries would help me with in terms of easing DOM manipulation.
Finally, I'd still choose jQuery over other libraries when limitations and restrictions dictate.
I'm working on dusting off the code for a side project that was in an old version of Bootstrap that required jQuery. Would use it again.
The DOM has native APIs for doing a lot of what jQuery does now, but last I checked jQuery was a lot more succinct, which means less code to write and less code to maintain than "vanilla". I think React might have it beat for intuitiveness though.
Yes, my company is. The code base is 8+ years old. None of the JS frameworks were out yet.
There's a lot of front-end interactivity that would be a lot easier if we moved to a front-end framework. We do want to use them, but it's a matter of balancing cost of rewriting, releasing new features and not breaking the old stuff.
Yes! I work exclusively with Adobe Experience Manager (AEM). It’s an enterprise CMS with a significant market share among Fortune 500 companies. AEM uses jQuery extensively. But more importantly, 99% of implementations I’ve seen rely on jQuery; mainly because Adobe uses it and because everyone is familiar with it.
I love jQuery. It’s a fantastic tool that give you great freedom . And with great freedom comes great responsibility, that is to write clean and maintainable code.
Also, would love your thoughts on this:
Tell me about jQuery Patterns!
Ahmed Musallam ・ 1 min read
I just did a 36,000 line rewrite from jQuery server rendered Django to Vue SPA + Django with Django simply acting as a REST API. It was a massive undertaking and probably the biggest single hurdle I've had in my career. Lots of late nights at the office. The end result is a pleasure to work in and the users seem to prefer it as well.
Been using Angular for a while, the funny thing is all those famous nitty npm packages we use in angular are only a wrapper over jquery libraries.
You can open your node_modules folder from angular project and
open any js file to see it first hand.
My personal favourite is **bootstrap **package and inside it's js file you will find most of jquery code been wrapped and put to use.
Internet is very biaised because those who blog are naturally the ones who are the people to keep up with latest frameworks. But there are a huge number of legacy developers you never see online especially in big corps who are still coding in jquery, though more and more have switched to at least angular.
I still use it on the regular! Sometimes it's just quicker and easier to use jQuery rather than using vanilla js. If I'm building some big complicated build I look at taking a better approach than jQuery but for a simple 1-5 page website jQuery is the way to go! Idc what the JavaScript police say! Lol
This is my point of view as well. I use jQ all the time for quick updates for clients or small projects. Yes we use modern frameworks like React, but a lot of our clients are on WordPress sites or similar. It's fast and easy for DOM manipulation and I don't see a reason to toss it out just because it's not the latest toy.
Absolutely! In my experience many freelancer's works actually use jQuery
Our legacy code is in initial versions of Ember and so we are still using it.
Its real pain when you work in React and old versions of Ember side bu side
Yup, still using it. Sometimes, when there's only little js needed at the frontend, I prefer it over writing an extra React.js or Angular app.
I'm the maintainer for github.com/NicolasCARPi/jquery_jed...
jQuery is still relevant, see arp242.net/jquery.html
Yup, I have no idea how JS works and the JQuery tutorials / documentation were pretty good :) I last used it a couple of weeks ago
I don’t know about this, but I’m currently taking a coding bootcamp at Rutgers University and it’s on our curriculum. In fact I think we’re starting it on Sat.
Can use it in some not so big projects. Sometimes I need to use it if some other library depended on JQuery
I primarily use it in WordPress and Drupal settings because it comes baked in.
Actually most of the modern PHP scripts are still using jQuery. Just check the hottest PHP scripts on codecanyon.
Everyone using WordPress, raise your hand ✋
not as much as I used to. Most of the project that I work on are either on vuejs or reactjs.
Yes for legacy projects I sadly do.
Still have some jQuery widget in a couple legacy apps I maintain
I still use jquery for many projects. It is so easy to integrate and many commands are just so deep in my head.
It's fast and good.
A saying describes it quite well: "Never stop a running system! :)