This is how to deploy your SvelteKit app using Netlify. You will need to have your app’s code in a repository on GitHub. If you need help getting started with Git and/or GitHub please visit my site Beginners Guide to Git & GitHub.
First you will have to prepare the code to be ready for Netlify.
npm i -D @sveltejs/adapter-netlify
Before you add the Netlify adapter you will have the auto adapter that is installed when you initialize your SvelteKit project. Once you install the Netlify adapter you will need to change the svelte.config.js file, which you can do by switching out the import source as shown below. Simply replace adapter-auto with adapter-netlify. At the Netlify adapter GitHub page they have an example including options you can use, but it will work as is.
import adapter from "sveltejs/adapter-netlify";
export default {
kit: {
adapter: adapter()
}
};
[build]
command = "npm run build"
publish = "build"
npm run build
git add -A && git commit -m "message about commit" && git push
Whenever you make changes to your website and push the changes to GitHub, Netlify will rebuild your site and re-deploy it. It may take a minute or two, but once it is done the changes will be reflected on your site.