▲ | hasanhaja 3 days ago | ||||||||||||||||
Why does this have to be the baseline architecture when you can render the HTML on the server with the template and data? Why send the data and the JavaScript to parse that data and transform it into HTML in a users browser when you can do it on the server? For requests after the first, you can still continue to send the rendered HTML to be placed into the document. Here's an example using HTMX: https://htmx.org/examples/lazy-load/ | |||||||||||||||||
▲ | 8n4vidtmkvmk 2 days ago | parent [-] | ||||||||||||||||
If your app is simple enough, go ahead and do that. In nearly every app I've worked on, I eventually need some dynamic piece of content. Like even a date picker, so you really want to call the server every time the use wants to go to the next month? | |||||||||||||||||
|