hydrate
This article is a stub. You can help the IndieWeb wiki by expanding it.
hydrate is web developer jargon for the process of client-side JS taking over a DOM that was generated on the server, adding it to JS data structures, adding event handlers, β¦ instead of generating page elements only on the client or entirely replacing those sent by the server. Due to complexity typically a process integrated with larger frameworks (example: vue.js documentation) that use the same code to render on the server and on the client.
Indieweb Examples
- Template:jolvera uses it for https://jolvera.dev
- https://chat.indieweb.org/2019-06-12#t1560346497762100
- "jamietanna[m]: first render is from the server, then it hydrates the markup with React and add all the goodies. And for navigation https://github.com/zeit/next.js/#prefetching-pages" [ @jolvera] June 12, 2019
- https://chat.indieweb.org/2019-06-12#t1560346497762100
See Also
- Criticism: switching from delivering HTML+CSS to delivering a hydration system multiples the risks involved: https://twitter.com/slightlylate/status/1592834652213248000
- "What this means for frontend is that when someone suggests moving some part of a site from HTML + CSS to something that is "hydrated" by JS, know that they are not proposing a small thing. They're multiplying your risks." @slightlylate November 16, 2022