Even when using a framework I usually include jQuery to smooth out the edges where the framework does not behave as I would have expected, or seems to make implementing a part of the intended UX awkward or complicated.
Is anybody else still relying on jQuery in some capacity, and if so, what value do you get out of it? Do you use it along with one of the major frameworks, or together with smaller libraries? And do you plan on dropping it soon?
In hindsight I have been guilty of resume-padding and falling prey to hype by choosing to build on technology not appropriate to the problems at hand. And I find myself reverting back to basics, with bits of new tech sprinkled in.
My reversions:
- React, flux, redux ----> jQuery and intercoolerjs when needed
- Swarm, Kubernetes ----> Just plain old docker on single machine, scale vertically with cores and memory when needed
- Microservices first ----> Django Monolith first, then break out microservice when needed
- API Gateways (kong, Azure) ----> Nginx reverse proxy with hand-edited configs.
I can do this because I have chosen to work on niche problems and smaller markets. Scale is not my issue, even in very successful scenarios.I see jQuery will have a place in my stack for some time to come. It just works (tm), and it plays well when I need to level-up with wither intercooler or yes -- backbone.
Another benefit is that it is a low barrier to entry for junior developers. It allows me to establish a baseline knowledge, and then mentor other things like workflow, code structure, and architectural things rather than chasing weird configuration things inside of webpack or the taskrunner-du-jour.
But, sadly, it feels like openly selling yourself as a consultant in these technologies would be a form of sabotage and limit your opportunities considerably.
I've just had an idea for branding myself: artisinal, vintage web development using traditional jQuery / Django. :)
Regarding the discussion Micro-Service vs Monoliths. I agree that a monoliths gets you started quicker. But it also asks a lot of discipline from the programmers. E.g. 'stick to your domain boundaries', 'Don't take that shortcut of direct db access because business needed the feature yesterday', etc. Otherwise you'll have big troubles splitting it up later on. [2].
I REALLY REALLY REALLY like that micro-services make your boundaries explicit and enforce you to write contractual APIs aka Interfaces. Much more than all the promises of scalability etc.
[1] https://github.com/MarkusPfundstein/microservice-service-dis... [2] https://martinfowler.com/bliki/MonolithFirst.html
When I buy a car I’m buying the benefit of it, which is convenient transportation. I don’t really think that I’m buying a drive train, engine, steel body, airbags and whatnot.
Some companies have GitLab workflows that also deploy successfull builds automatically, checks are there problems in that deploy, and rollbacks automatically when needed: https://twit.tv/shows/floss-weekly/episodes/473?autostart=fa...
Such workflows could also be made with for example: - Huginn https://github.com/huginn/huginn - Flogo http://www.flogo.io
Docker pull <image name>
Docker container stop <container name>
Docker run <opts> <image name>
This does result in a “hiccup” for any clients wanting to connect. They will see a 502 gateway error at which point they should retry with exponential backoff.And that is the trick — make the client retry with the exponential backoff. Document it as the expected behavior when that event arises. And for our traffic patterns this is acceptable.
If you're doing projects with light functionality and already know jQuery cold, you really don't gain much from React, Vue, et al for that project. You may gain something personally (career path, different way of thinking, etc), but that is a different topic.
For anything slightly above the basics, I'd recommend Vue as a great alternative to jQuery. No build tools required and it's easy to stay in the realm of plain HTML, CSS, and JS. It also "progresses" really nicely if you have more complex needs later on -- that would be a main benefit over a tool like jQuery.
https://trends.google.com/trends/explore?date=today%205-y&q=...
5 years ago, jQuery was twice as popular than it is today. But I wouldn't call it dead just yet. It's a work in progress.
By the way - one of the things that killed jQuery is HTML5, it's not only Vue and React for more advanced features, a lot of people used jQuery for basic DOM manipulation, which today you can probably get away with just fine with the HTML5 DOM API, since the addition of the querySelector APIs and things like CSS's classList APIs.
And Web Components are starting to destroy jQuery Plugins.
Since then, I had one project where using jQuery and jQuery UI was dramatically easier than building out a datepicker input by hand; however, for everything else, vanilla js is my go to.
It was spectacular 10 years ago, but now it's pretty much useless to me. Most everything either shouldn't be done in javascript or has a native replacement – at least with polyfills and Babel that I need for all development. I would love to remove it, but it would take far too long and provide little customer benefit (remove the library download), so it's only removed when something is refactored.
If I look at the number of open source 3rd party js libs that support it, they are around 180k LOC.
Eventually, I do see a project that ports over the entire js code over to ES6 and Vue.
When it becomes very much not faster is when you have a bunch of jQuery poorly (or "customly") organized and someone else has to wade back through.
Vue is awesome though, really liking it. Sometimes I use Vue and jQuery together to take advantage of jQuery plugins. Does this make me a bad person?
My end users don't care! YMMV
Have you got numbers to support that? Because I think it's wrong.
If you want some numbers, compare e.g. the dates on popular HN posts for jquery[1] vs react[2] and vue[3]. Most popular articles for jQuery are 4-6 years old, while for React and Vue the popular stories are much more recent. Of course, HN might be somewhat special.
[1]: https://hn.algolia.com/?query=jquery [2]: https://hn.algolia.com/?query=react [3]: https://hn.algolia.com/?query=vue
Marketing + meme.