3 ms·
> Performance is higher with the server because the HTML is already generated and ready to be displayed when the page is loaded. I don't see why we should assu
by zeroonetwothree 4y ago
> Performance is higher with the server because the HTML is already generated and ready to be displayed when the page is loaded.
I don't see why we should assume the server is faster at processing the input data into HTML than the client is. It could very easily be that the client device does this faster. SSR additionally prevents progressive rendering, since you must generat eall the HTML ahead of time, which can make pages feel slower. Also HTML+JS data size can be larger than data+JS size (and you /may/ need the data anyway for the SSR version to do hydration). Of course all this varies, which is why it's silly to claim a general principle.
- mmcnl 4y agoPerformance is not _only_ determined by the processing time. Downloading the JS bundle and parsing it takes a lot of time. There's no need for that on the server. First page load is always very slow for CSR. Any client-side navigation after that is fast. SSR has a low initial page load and uses client-side navigation after that.