Introducing react.dev
Why are so many comments about class components, I thought we ended that debate 3 years ago?<p>Hooks are better because they allow you to reuse component logic, impossible with class components. They solve all the issues and gotcha&#x27;s of HOC&#x27;s.<p>Don&#x27;t compare class components with hooks, compare HOC&#x27;s with hooks.<p>The best way to grow appreciation for hooks is to try wrapping many HOC&#x27;s and deal with conflicting props and &quot;innerRefs&quot;. People seem to very easily forget the horrors of the old.<p>Also lets be real, hooks aren&#x27;t that bad. Yes dependencies arrays and useEffect take some getting used to, but I rarely get into situations where I actually get into questionable territory. Use react-query&#x2F;swr for fetching, use Zustand (or whatever) for state, and you cut out 95% of the problems.<p>Anyway, the new docs are great, well done, nice work!