Search code examples
sveltesame-origin-policysvelte-3sveltekit

Run a sveltekit app from file:// with no server


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?


Solution

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