Unveiled December 14, the milestone release makes SvelteKit the recommended way to build all Svelte applications, the Svelte development team said.
Svelte team members said Svelte makes it easier to build user interfaces than working with the DOM directly. Svelte's approach differs from frameworks such as Vue and React in that work usually done in the browser is shifted to a compile step on the server when building an app.
SvelteKit defaults to client-side navigation after the initial server-rendered page load, enabling faster page transitions, state that persists between pages, and less data usage. SvelteKit also avoids rerunning third-party scripts like analytics on every page load.
Developers, the Svelte team said, can build apps with personalised data without performance-hindering, layout-shifting effects of fetching from the browser after page loads.
SvelteKit allows a page being viewed to be prerendered while the REPL is rendered with dynamic data. Switching between the two uses a single line of code. Apps built with this approach are called transitional apps.
While the SvelteKit CLI needs Node.js installed locally, the framework itself has no dependencies on any platform. SvelteKit leverages the Vite build tool, with out-of-the-box support for hot module reloading and TypeScript.
When starting a SvelteKit project, developers will be asked if they want to add TypeScript, ESLint for code analysis, Prettier for code formatting, Playwright for browser tests, and Vitest for unit tests.
Looking forward, the Svelte technology roadmap includes capabilities such as incremental static generation, granular control over the deployment region and runtime, and image optimisation.