Server-side Rendering in JavaScript: A Modern Approach
Let’s talk about SPAs. It all starts from a blank page which is subsequently filled with HTML and JavaScript. If we take PHP pages as an example, they already come bundled with the server, which is an advantage in terms of performance, right? For situations like these, server-side rendering frameworks (such as Next.js) come to the rescue. They process the code on the server-side to pre-fill the HTML result page with something (if not the whole page) before it reaches the browser.