4 ms·
Not at all, unless there is an absurd amount of content on the page that is unrelated to the data being fetched (like title, footer, sidebar). An HTML-table, fo
by ratww 5y ago
Not at all, unless there is an absurd amount of content on the page that is unrelated to the data being fetched (like title, footer, sidebar). An HTML-table, for example, is in the same ballpark size-wise as a JSON representation of the same data. And that's without taking into account the fact the JSON can potentially carry more information than necessary.
Facebook is an example of a website where there is such an absurd amount of content that's not the focus of the page: the sidebars, the recommendations, the friend list of the chat, the trends, the ads. It sorta makes sense for them to have an SPA (although let's be frank: most people in slow connections prefer "mobile" or "static" versions of those sites).
The impetus for SPAs was never really speed. The impetus for SPAs is control for developers, by allowing navigation between "pages" but with zero-reloads for certain widgets. It was like 90s HTML frames but with full control of how everything works.