> React looks cleaner. It reads better at first glance. But that readability comes at a cost: you're trading explicit simplicity for abstraction complexity.
Not always, SolidJS code can look the same as React code, but what goes under the hood is very simple and straightforward.
It's very sad this is what's happening. React hooks was a major innovation but a very bad one, people in the front-end world seem to value more about radical innovation and marketing buzzwords like "functional UI" (which is not true) than truly evaluating a system. The earliest momentum started from trend chasing, also a lot of people use React because they see the JSX looks pretty nice in the examples.
Based on how they are run they are completely not just ordinary JavaScript functions, hook era components are also not just JavaScript functions, it's a very complicated system. React calling them "just functions" is untrue, just marketing buzz words, and it leads developers into traps.
Many functions can only be called in a certain context. Calling them "not functions" is misleading imo because it implies those functions are compiled out or something, like `$state()` in Svelte.
Yeah they themselves are functions but how they're called are managed by a complicated system, I think treating them as a separate new concept is less misleading than calling them plain functions
Well they aren't plain functions, they're like lifecycle methods for the component with an implicit `this`. Perhaps that's how they should be described.
I'm pretty sure this is also untrue. AFAIK React has never used that phrase (and at the very least, I can't find it anywhere official right now), it came from other people convincing newcomers that hooks aren't something more complicated like objects (comparing to class-based components). React has always treated them as special functions, hence always prefixing them with the word "use".
haven't updated in 6 years...