Live data from Hacker News

jQuery 4

blog.jquery.com

51–60 of 313 posts

Re: jQuery 4

#51
Whenever HTMX comes up here, I always think "isn't that just some gobbledy-gook which replaces about 3 lines of imperative jquery?"

Anyway, jQuery always did the job, use it forever if it solves your problems.

Re: jQuery 4

#52
post #38
post #9

Earlier quoted context omitted.

jQuery does a lot more though, and includes support older browsers.

> includes support older browsers Which is entirely the issue. Supporting a browser for the 10 users who will update jQuery in 2025 is insane.

It is definitely more than 10 users.

Re: jQuery 4

#53
post #9
post #5

Even after migrating to ES modules, jQuery is still somewhat bloated. It is 27 kB (minified + gzipped) [0]. In comparison, Preact is only 4.7 kB [1]. [0]: https://bundlephobia.com/package/jquery@4.0.0 [1]: https://bundlephobia.com/package/preact@10.28.2

jQuery does a lot more though, and includes support older browsers.

Officially they state they only support 2 latest versions of chrome. But considering their support of IE11, that's actually a lot.

Re: jQuery 4

#54
post #23

Earlier quoted context omitted.

Unfortunately, nowadays writing userscripts is much harder than it used to be. Most websites are using some sort of reactive FE framework so you need to make extensive use of mutationObservers (or whatever the equivalent is in jQuery I guess).

Very true. I guess that depends on what websites you find issues with? I just checked mine and all of those are quality of life improvements for fully server rendered sites like HN or phpBB forums.

Yeah, I mostly use it for QoL improvements but for work related things. So Jira, Bitbucket, GitHub, Linear etc. basically whatever my employer uses. Back in the early 2010s most of that software was fully server rendered. Nowadays it's pretty rare for that to be the case.

I just try and get LLMs to do it for me because I'm lazy, and they like to use setInterval instead of mutationObservers and if it works, I just live with the inefficiency.

Re: jQuery 4

#55
post #4

Unbelievably, still supports IE 11 which is scheduled to be deprecated in jQuery 5.0

Backwards compatibility. Apparently there are still some people stuck on IE11. It's nice that jQuery still supports those users and the products that they are still running.

This is the part that I find the strangest:

> We also dropped support for other very old browsers, including Edge Legacy, iOS versions earlier than the last 3, Firefox versions earlier than the last 2 (aside from Firefox ESR), and Android Browser.

Safari from iOS 16, released in 2022, is more modern in every conceivable way than MSIE 11. I'd also bet there are more people stuck with iOS 16- than those who can only use IE 11, except maybe at companies with horrid IT departments, in which case I kind of see this as enabling them to continue to suck.

I'd vote to rip the bandaid off. MSIE is dead tech, deader than some of the other browsers they're deprecating. Let it fade into ignomony as soon as possible.

Re: jQuery 4

#56
post #51

Whenever HTMX comes up here, I always think "isn't that just some gobbledy-gook which replaces about 3 lines of imperative jquery?" Anyway, jQuery always did the job, use it forever if it solves your problems.

The problem with jQuery is that, being imperative, it quickly becomes complex when you need to handle more than one thing because you need to cover imperatively all cases.

Re: jQuery 4

#58
post #5

Even after migrating to ES modules, jQuery is still somewhat bloated. It is 27 kB (minified + gzipped) [0]. In comparison, Preact is only 4.7 kB [1]. [0]: https://bundlephobia.com/package/jquery@4.0.0 [1]: https://bundlephobia.com/package/preact@10.28.2

> Preact is only 4.7 kB

Is there some outlier place where people using virtual DOM frameworks don't also include 100-200kb of "ecosystem" in addition to the framework?

I suppose anything is possible, but I've never actually seen it. I have seen jQuery only sites. You get a lot for ~27kB.

Re: jQuery 4

#59
post #45

jQuery was peak JavaScript. Good times, I'm glad it is still around.

It is still used by many websites.

Indeed. Though a lot of its feature found their way into plain vanilla Javascript and browsers, the syntax is still so much easier with jQuery.
Post reply on HN