Preparing a SvelteKit application for Deployment
If you want to deploy you SvelteKit application for deployment, you must first follow this guide.
Preparing your Application for development
In you local install run the following command. This will install the adapter needed for deployment to a Node.js server:
npm i -D @sveltejs/adapter-node
Now add the adapter to your svelte.config.js
Don't copy the entire thing literally. Copy the import and the kit block. Remove the auto adapter line.
import adapter from '@sveltejs/adapter-node';
export default {
kit: {
adapter: adapter()
}
};
You should have run the following commands and make sure they're error-free on your local install.
npm run build
Check if your sites works if you run:
node build
PreviousInstalling Locomotive Scroll with Svelte 5 and SvelteKitNextUtility Functions for URL Handling in SvelteKit
Last updated