Hacker News new | ask | show | jobs
by dasb 1837 days ago
Is it possible to achieve the same thing just with Svelte + SvelteKit and some configs?
1 comments

Yes, with SvelteKit you can use the static adapter to generate static html files for your routes. It's also possible to control this on a page by page basis.
Thanks.

What if only some components in my page require Javascript? Can the same "partial hydration" be achieved?

No. Svelte are big proponents of the SPA pattern so I'm doubtful they would ever build something like this.
Svelte by its nature only generates JS for the dynamic pieces of the page, if you’re using SSR it’s already “partially hydrated”.

Vue3 can also ignore static parts which gives similar benefits.