3

I basically am wondering the same things as in this post except I need it for sveltekit with adapter-static not just svelte with rollup. There are basically 2 issues:

  1. SvelteKit doesn't allow you to use ./ in the paths.base config option and
  2. SvelteKit comiles to js modules which don't work from file because of CORS.

Any idea how to fix those issues?

3
  • 1
    May I ask why you want to run SvelteKit without a server, as this could affect how you would fix the problem? Commented Jun 18, 2021 at 9:09
  • 3
    My client wants to be able to open it with a double click on the html file Commented Jun 18, 2021 at 13:08
  • Unfortunately, it seems that http or a localhost server (npm run preview) is needed to run SveteKit apps. Commented Jun 18, 2021 at 13:33

1 Answer 1

1

There's an issue to track this: https://github.com/sveltejs/kit/issues/907

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.