3 ms·
First of all, I just want to empasize there exist kinda three layers: data -> presentation -> decoration. HTML still acting as a presentation, but in SPA it als
by byko3y 6y ago
First of all, I just want to empasize there exist kinda three layers: data -> presentation -> decoration. HTML still acting as a presentation, but in SPA it also acts as a decoration together with CSS. Secondly, we need to find what the data is. Because often the data is on the server database, while everything else is transmitting and caching the original data.
>In my current SaaS product, if we were doing SSR instead of client side rendering, our hosting costs would be through the roof right now
It's good you mentioned your product instead of generalizing implicitly. Because SSR in some cases allows you to prerender pages and host them statically, thus significantly reducing server CPU and RAM load, and also making page loading time very fast.
>Plus, using service workers, it can work offline, which is not really possible with SSR
Similar scenario is possible with SSR, allowing for completely offline operation. SSR implementations usually require scripts to be run on the client side, and also allow for defining explicitly server-side-only and client-side-only scripts, including full transition into kind of SPA for specific pages, as well as a full SSR prerendering with dead-static content on both server and client. And gzip can help to reduce the bandwidth required.