ATRIUMsearch → argument graph
ClaimVideo · 37:12 — 38:42

React's hooks model is flawed because every hook inside a function component gets re-run on every single render, whereas frameworks like SolidJS and the new Gia framework run components once and use class-based state and methods to avoid that overhead.

CJ criticizes React's hooks system for re-running all component code on every render, and praises the new Gia framework (like SolidJS before it) for running components once and using class-based state/methods instead. ✦ AI generated

CJ Reynolds · Syntax · 2026-07-06 · original ↗

starts at this moment · 37:12

One of the things I don't like about React is the entire hooks system. The every hook that you write inside of a component is run on every single render. Not necessarily invoked, but it's recreated on every render... And I don't like that. I think it's a very silly model.

verbatim transcript · starts at 37:12

Transcript · around this moment

37:12>> I like about it as well. I will say I've I've been a recent critic, a loud critic of React and um I will uh give you more details because one of the things I don't like about React is the entire hooks system. The every hook that you write inside of a component is run on every single render. Not necessarily invoked, but it's recreated on every render. Basically, everything you put

37:34inside of React function component >> has that code has to run on every rerender. And I don't like that. I think it's a very silly model. And SolidJS solved this where essentially you write your SolidJS component, it runs once and then you have effects that can potentially run later, but you don't have this whole idea of this component runs over and over again. >> And GIA does that as well. So they they

37:57don't run over and over again. And the idea is if you're going to build a component that needs internal state, you actually use a class component. So it kind of goes back to like the old React way of uh class extends component and then instead of a render function you have a template function. But what that means is you can have class methods. So you can have like state update methods

38:16or effects but you just call them as instances on the class. And I actually like that I it's a better mental model for me in terms of what the code is actually doing versus how I write it. Because in React you have all these use effect use memo use callback. And it's very hard to reason about like what order does it get called in, where does it live, that kind of thing. So you

38:37essentially if you want a component that has state, you have to create a class that extends component. But they [snorts] also support functional components but purely for presentational UI. So the a functional component looks exactly like a function component would in react except there are no hooks. You can't have any use effects. You can't have any variables or state inside of here. It's purely presentational. And so

38:57I like that split where like if you want interactivity, if you want state, you have to put it into a class component and then you have to create methods on it. Um, so I I'm I'm I'm a big fan of that. Um, they have an example like there's a a doc on their site called React versus GIA. I would say take a look at that if you're a React developer

Related moments