DEV Community

loading...

Discussion on: What is Virtual DOM? How Virtual DOM works ? What is Reconciliation ? What is diffing algorithm? What makes React so fast ?

Collapse
thesanjeevsharma profile image
Sanjeev Sharma

So, why do people use it? Community? Or is it easy than others?

What's your view?

Collapse
quochuytlbk profile image
Huy Ta Quoc

I don't think React is easier to use than the others. It has certain gotchas that even experienced React developers sometimes stumble upon (e.g. stale states, stale closures). You also need to manually prevent the application from not re-rendering components too much (by using useMemo, useCallback, memo, etc.) or there'll be performance issues. There are also a few more things that people who are new to React will have a hard time wrapping their mind around.

So, it is slower, heavier, and more complex than its competitors. Why do people still use it then? I guess it's because React just happens to be one of the first groundbreaking technologies of its kind. If, for example, SolidJS (the fastest and lightweight library that has somewhat similar APIs to React) had been there instead of React, I guess it would become as popular as React right now.

For me personally, the reason I still use React is because of its ecosystem. React is so popular that you can almost find a mature, invested solution to any problem you're facing out there, written in React. That's not something you can easily find in its competitors.

Thread Thread
vahlcode profile image
Valentine Elum

Exactly.

Some comments have been hidden by the post's author - find out more

Forem Open with the Forem app