| Multi-page apps | Single-page apps |
|---|---|
| Lose state across pages | Maintain state across pages |
| Repeat code | Keep code DRY |
| Reload every navigation | Load only once |
All files are loaded at once...
Why URLs?
Console example:
history.pushState({}, "", "/mypage")
Load async components preemtively.
Can happen when client is idle or in response to a particular interaction.
SPA require frameworks which can be large:
First load is slow
With SSR, a parallel Vue client runs on the server and immediately sends HTML before client downloads Vue.