DEV Community

Discussion on: Patterns for Building JavaScript Websites in 2022

Collapse
 
codewander profile image
codewander

You don't really need JavaScript in title. You could also include Jekyll, Hugo, and newer ssr like Laravel + http caching as an option

Collapse
 
davedbase profile image
David Di Biase

Laravel and HTTP caching are new?

Collapse
 
codewander profile image
codewander

I am thinking of the turbo/hotwire/livewire/liveview family of ssr. I don't know how old livewire is.

Thread Thread
 
peerreynders profile image
peerreynders • Edited

I would in concept describe those as server rendered SPAs requiring a continuous high quality, high bandwidth, low latency connection. As per navigation they classify as a "hybrid" - a complex version of Turbolinks - where client state is managed server side.

The term SSR keeps being used in a variety of ways.

In many contexts it implies firing up client side JavaScript on the server to generate markup and state to be sent to the client which then takes it and runs with it.

I personally avoid using "SSR" to mean "Classic SSR".

Thread Thread
 
redbar0n profile image
Magne

«The Rails Hotwire» reference here should probably be «Hotwire Turbo Streams». Since Hotwire is written in TypeScript and can run with several types of backend (like Django, with turbo-django).

«Turbo Streams deliver page changes over WebSocket, SSE or in response to form submissions using just HTML and a set of CRUD-like actions.»

turbo.hotwired.dev/

Thread Thread
 
peerreynders profile image
peerreynders

Based on the this "NEW MAGIC" was renamed to Hotwire in December 2020. I have no doubt that the implementation continued to evolve.

The point really is the order of emergence:

  • Phoenix LiveViiew
  • Laravel Livewire
  • Rails Hotwire
Collapse
 
peerreynders profile image
peerreynders • Edited

You could also include Jekyll, Hugo, and newer ssr like Laravel + http caching as an option

Those technologies are primarily Gen 0 technologies despite the fact that they are in modern use.

Given the various classifications given here Gen 3 solutions are also MPAs but for the time being they will be heavily reliant on server or edge side JavaScript especially if they are aiming for "resumability" until such point where code generation can replace the server side code with something else.

MPA, "Server-routed multi-code entry site experience", doesn't imply pre-2010 style dynamic server side rendering of (just) HTML.