DEV Community

Tomasz Łakomy
Tomasz Łakomy

Posted on

Reasons why React is better than jQuery

🤔

Top comments (12)

Collapse
 
ben profile image
Ben Halpern

Anyone who's tried to create a complex interface with evolving context and state with jQuery

Collapse
 
tlakomy profile image
Tomasz Łakomy • Edited

I used to work in a large Backbone + jQuery codebase

There were 4 different event buses and the entire app worked by accident

Collapse
 
praneet_ro profile image
Praneet Rohida • Edited

tl;dr:

Collapse
 
ryan_dunton profile image
Ryan Dunton

A few years ago I had to make a quiz web app using jquery and we had to remove all children DOM elements then recreate them whenever the content changed for XSS reasons. That is when I realized React was much easier than jQuery for state management

Collapse
 
nickytonline profile image
Nick Taylor
Collapse
 
pcrunn profile image
Alexander P. • Edited

i wouldn't really compare those two since react is a component library while jQuery is a library that makes DOM management easier

EDIT: language -> library

Collapse
 
leighshammer profile image
Leigh Barnes

Why is this even a question? JQuery for what it was in the day was great. However as with every thing days pass, and it fell behind.

There is no way I want to go back to rolling statemanagment and event listener binding and rebinds. It's benefit of easy Dom selection, is with current browser support obsolete.

I loved JQuery way back, buy react is a different thing all together. JQuery has no real place in modern web dev. IMHO.

Collapse
 
pankajpatel profile image
Pankaj Patel

For large scale apps, React provides the necessary blocks to keep the project manageable.

For small projects and simple homepages; don't matter. Both can be overkill or underdogs.

Collapse
 
ogrotten profile image
ogrotten

Reasons why React is better than jQuery

It's not jQuery.

Collapse
 
selbekk profile image
selbekk

One less letter. Bytes matter!

Collapse
 
eddyvinck profile image
Eddy Vinck

Try building an actual app with jQuery and then having the design or requirements change significantly for a v2. In jQuery, this can mean having to rewrite your app entirely.