"I’m waiting for the day when the only way that you build UI, the only way you can build UI is with the React paradigm."
is scary.
"I’m waiting for the day when the only way that you build UI, the only way you can build UI is with the React paradigm."
is scary.
Just my 2 cents though.
TLDR React is not efficient enough, the performance requirements of next-gen apps of 2020s is going to break React because rendering is not incremental. These warts are basically places where React departs from pure functional programming to achieve ease of use.
1) Fundamental performance problem in render-tree-pruning (it is not truly reactive, it does more work than necessary). This is not an issue today except in the most sophisticated apps, but in apps of the 2020s it's going to be a huge problem. My startup http://hyperfiddle.net/ spends a great deal of energy trying to make React faster, it all boils down to forceUpdate which breaks the "functional programming" philosophy and makes the programming model significantly worse.
2) The solution to (1) is a reactive, spreadsheet-like programming model that generalizes to more than just the View-as-a-function, but also to the rest of the functions. React's solution injects fat "Component" instances everywhere in the view; its not actually just functions, so it breaks for the other expensive computations in the app, which will also need to be optimized in the 2020s.
https://github.com/slamdata/purescript-halogen is the best shot i know of at solving all this; it may be 5 more years yet until this is simplified enough to become mainstream, but all-in-all the ever increasing complexity of apps means truly efficient rendering is inevitable, and React is not that.
Apps are like moores law; every 1.5 years the sophistication doubles.
In React a view is a function of state:
const Header = ({ color, children }) => <h1 style={{ color }}>{children}</h1>
// Gets transpiled into:
const Header = ({ color, children }) => createElement('h1', { style: { color } }, children)
<Header color="red">hello</Header>
A large part of my career was about XAML/WPF/SL. I know it took me a year or more to really understand it deeply, being able to extend and do everything i wanted. I came to the same state 60 minutes into React. The pattern behind it does make many things easier. And that is an understatement. I believe that's also the main reason Microsoft itself is betting on React for cross platform and native apps as well as extension eco systems:https://github.com/Microsoft/react-native-windows