Skip to content
loading...

re: No, React didn't kill jQuery VIEW POST

TOP OF THREAD FULL DISCUSSION
re: I agree 100% with this except the "you probably shouldn't use jQuery for a new project." I love that jQuery is a drop-in that can live and work alo...
 

Yeah, I agree with all of that... Except I still think the downsides of library size still makes the tradeoff not worth it.

This isn't a hill I'd die on, but it's the side of the coin I'd fall on. If I'm going to drop in a convenience lib I'd rather go with something a lot lighter. Of course if you're building desktop software, internal tools, etc—it probably wouldn't be a big concern. But if you're building for the masses I'd try and be stricter on my budget than to immediately reach for jQuery, even if it is slimmer these days than its peak.

 

You could always use JQueries native tools to build a smaller library with only the components you need if space is a concern (which it definitely should be)

:)

 

An ongoing joke I have with some of my dev friends is that we argue and debate over payload sizes and when we're done, we put our headphones on and start streaming Spotify at 320 kbps. Haha.

Fair points. However, comparatively, the size of jQuery is relatively small or on par with other libs. jQuery core is 31.3 KB compressed. Meanwhile, Notion, AirTable and other modern apps have JS payloads of over 7 MB, and they don't have a shortage of users. Depends on the target users.

I'd say that the size alone of the libs shouldn't be the only measurement. We should consider the added benefits of that payload throughout the system to justify its size.

If Notion and other ship a lot of JS it doesn't mean it doesn't affect user perf. Yes, there are target users, but if we ship just less js, everyone will be happier. Both users with speedy internet and slow one.

FYI, there are some jQuery clones rewritten in ES6 so you can ship as low JavaScript as possible.

kenwheeler.github.io/cash/

code of conduct - report abuse