#When pages rerender server side their
1 messages · Page 1 of 1 (latest)
Got it, so really I can ignore the fact that the render is happening on the server and treat it as a client-side traditional react update (I'm pretty new to react, but have some experience).
I guess the goal is to not use traditional react hooks higher up in the page component hierarchy (which I believe is something you wanted to do in traditional react) and instead push state changes (like router updates) to the smallest client component to limit the "blast radius" where you don't have access to server resources.
The most important things are that a lot can be done server-side, client components aren't bad, ideally they are leafs of the component trees, but sometimes they are interleaved which can be fine.
And many classic React rules still apply.
And as I've shown you client -> server state propagation is done using search params or cookies/headers
yup yup, makes sense. So if you keep client components as leaves in the DOM tree the server component may have to create refs between them? Not sure what you mean by interleaved in this case.
Interleaving means nesting within each other
<Server>
<Client>
<Server>
This is legal if done right and sometimes necessary, but less idiomatic
oh interesting, I didn't even realize you could put a server component inside a client component. But that makes sense with the page hierarchy stuff.
wow you've been so so helpful, learned a lot!
The repo from earlier is the source code from our webinar. The readme has a link to the YouTube recording. In case you have enough time you can 1.5x me and watch the video to see a quick intro to the most fundamental basics.
But it barely covers anything, so it might be good enough to check out the repo and run it yourself.
perfect, will read through the repo and watch the webinar!
thanks too, the webinar looks promising
oh this webinar is sick!
what if we have some large payload, too big for url? Should we store it inside headers, and that's it? That is quite a mental shift!
(sorry if it is explained later in the video)