Maybe you've heard the term Resumability thrown around recently. Maybe someone gushing over Miško Hevery's new Qwik framework. Maybe you've heard m...
For further actions, you may consider blocking this person and/or reporting abuse
I guess this exact problem is why they specced the
datetime
attribute — but you have to remember to use it:…which presumably Resumable frameworks obviate, by remembering everything for you!
Ok so a timestamp might have been not the best example. My point is that you needed to serialize the full data in addition to the final output. Whether that is in a script tag or as another attribute in HTML is still more of the same.
No doubt, I like this idea. It requires us to serialize all states and attach them to HTML events. I dare not say that it can carry large and complex applications, but for the vast majority of static single pages, this is a very good idea.
Sorry I’m new to modern frontend engineering. Can anyone recommend an article explaining what hydration is in depth? I don’t understand when the server will pause rendering and send the code to the browser so that it resumes latter. Thanks
As like why pause and let the browser resume?
Thanks for the great article.
Does exist any code sample to know how does Resumability implement?
Thanks to you for fine-grained reactivity now we have more docs than before.
Is it possible to have code sample for both Resumability & (Re)Hydration? to compare and dive into it.
It's tricky because most of the challenge is the compiler transform and the serialization. It's not the code you write. And every frameworks' hydration works a little different so generalizing beyond the example in the article is also difficult.
The thing is it isn't hard to picture the simple case where someone attaches a global event handler and does things when the event is performed. But wrapping your head around the compiled output is a whole other thing. It is the same reason you don't see like a how Svelte compiles your code guide typically. But I hope if we can simplify this aspect we can maybe get to that point.
I like the last sentence and I hope this happens
Thank you for this and your other articles. They help me to understand the whole thing of rendering patterns!
Great article! Way to simplify and break-down such an advanced topic. Hopefully the knowledge shared here can help people from talking past each other when discussing these topics online.
I still don't exactly get it on a detailed level, but I appreciate the quality of the writing and exposition here!
What about observables? The analogue of pull based architecture. Everything is push based.
Yeah that is important part of making this happen since everything stems from events. But it isn't the full story since you still need to wire things up. A way to create the reactive pipe as it wakes up. And more, the huge expectation is continue to use familiar looking patterns. So hard to picture this without a compiler running over it. But reactivity is at the core of making this possible.
Nice high-level overview 👍
For more details see this talk from the creator: youtube.com/watch?v=Zddw6qy5pf0
I wish svelte would implement this