3 ms·
Congratulations to the team for releasing this. For someone who hasn't followed svelte closely, How much JS sveltekit ship by default using SSR
by akmittal 4y ago
Congratulations to the team for releasing this.
For someone who hasn't followed svelte closely, How much JS sveltekit ship by default using SSR
- swyx 4y agoits up to you - you can ship 0 kb of js if you want by turning off client side rendering https://kit.svelte.dev/docs/page-options#csr https://kit.svelte.dev/docs/page-options#csr and you have this choice on a per page basis rather than having to choose between a static site generator or a full SPA
- akmittal 4y ago0kb is best size of JS. Curious if I do want JS, how much is extra framework overhead
- crucialfelix 4y ago3kB
- swyx 4y agoas compared to nextjs’ ~150kb baseline? (not a real number im just guesstimating)
- crucialfelix 4y ago79.46 kb which includes React. That's never where the bloat comes from.
- akmittal 4y agoHow so, that 80 kb is bloat
- Existenceblinks 4y agoI believe that's already a compressed size (not minified) that means 200kB+ minified (zero app code).
- ovao 4y agoIt’s not directly comparable. Svelte apps have an extremely minimal runtime, because Svelte compiles components into largely freestanding chunks of code. The benefit is that for smaller apps, SvelteKit can be extremely lean, but the cost grows as the number of components and pages increases, since a number of attributes can’t draw from a larger, monolithic runtime (or set of runtimes). You do have to build moderately large apps to hit the point at which it’s a drawback however.