To me, this is the major driver of React's adoption and thus its success. Angular 1 took me a while to grok because there were so many moving parts. React's API is small and consistent a la JQuery, with the added bonus of being incredibly powerful.
To me, this is the major driver of React's adoption and thus its success. Angular 1 took me a while to grok because there were so many moving parts. React's API is small and consistent a la JQuery, with the added bonus of being incredibly powerful.
Stateful components are still hard to write (but are useful!).
Component lifecycle is not trivial and has many traps.
Newcomers put the craziest things in render(): side effects, etc. JS or even TS has no way to enforce that render should just return a VNode and do nothing else.
Data management is very, very difficult (beginners use props and state interchangeably).
Using higher order components or generally writing reusable components with clean APIs is an art in itself.
Separation of concerns in React is tricky too, as the community like to say "everything is a component" and this again has many traps.
The concept of keys or in general, when a node is reused vs when it's destroyed/recreated is not easily understood by newcomers too. But you HAVE to understand that to do animations, etc.
Also, you're productive if you don't care about performances; Once you do, you will be much slower. shouldComponentUpdate, using immutable updates everywhere, not creating lambdas everywhere on each render (idiomatic react), using virtualized lists, etc.
Let's not pretend React is very easy. It only is fairly easy if you compare it to something extremely bloated like angular.
Jeff not a few hours.
Just wanted to add some additional infos :p
Does React have some gotchas? Yes, but most of the time devs who get caught by those simply haven't read the very short and very good docs.
I've used loads of frameworks in my long programming career and React has been one of the easiest to pick up. Agreed that Angular is a bit of a nightmare. I studied that for months and still feel like a beginner even after building a side project with it.
I only started JS development because React enables me to build UI software like i always have done, except now in a browser.
React is components 101 for use in browsers. Flux is business logic 101.
Both (React/Flux) are great for devs that have no prior experience with building normal desktop applications. And ideal for devs that DO have that experience. That is where the (non-early) adoption wave is comming from imho.
"Hello world" in react is deceptively easy, that is true.