akiarostami / sveltekit-tailwind-blog-starter

An easily configurable and customizable blog starter for SvelteKit + Tailwind CSS

Home Page:https://pied-piper-blog.netlify.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[feature] could this repo support deploy for static

tuean opened this issue · comments

I like the style of this repo.

I would like to deploy this to nginx, so i change

import adapter from '@sveltejs/adapter-auto';

to

import adapter from '@sveltejs/adapter-static';

and change the adaptor to

adapter: adapter({ pages: 'build', assets: 'build', fallback: 'index.html', precompresses: true, strictpermalink: false }),

after i run npm run build, it shows many different exceptions.

So what is the corrent way to support deploye for static mode?

There are a couple of options that won't work in Static mode. Search, tags, and Open Graph image. All that should be removed or changed for this to work in static mode. Besides that, many packages must be updated (including Svelte/kit itself, since back then it was still RC).

Doing a static version of this has been on my to-do list for a while, but I don't have an ETA.

ok. i see.
I would deploy this by using adaptor-node instead. Thanks a lot!