diff options
| author | Mitchell Riedstra <mitch@riedstra.dev> | 2023-01-02 01:18:28 -0500 |
|---|---|---|
| committer | Mitchell Riedstra <mitch@riedstra.dev> | 2023-01-02 01:18:28 -0500 |
| commit | 9fbe8b79f7bc12a71b62722b06f7e93334da1a52 (patch) | |
| tree | 7d845be35268425289a5ce329440f673a6671846 /ui/svelte.config.js | |
| parent | 2d3b4c7fc74b377698cc2f554ae7ceac76bf616b (diff) | |
| download | paste-9fbe8b79f7bc12a71b62722b06f7e93334da1a52.tar.gz paste-9fbe8b79f7bc12a71b62722b06f7e93334da1a52.tar.xz | |
UI builds and embeds just fine, it mostly works.
Still need to address routing all requests to index.html
inside of the Go handler, shouldn't be too hard.
Diffstat (limited to 'ui/svelte.config.js')
| -rw-r--r-- | ui/svelte.config.js | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/ui/svelte.config.js b/ui/svelte.config.js index 87f198f..af0aad6 100644 --- a/ui/svelte.config.js +++ b/ui/svelte.config.js @@ -1,4 +1,6 @@ -import adapter from '@sveltejs/adapter-auto'; +// svelte.config.js +// import adapter from '@sveltejs/adapter-auto'; +import adapter from '@sveltejs/adapter-static'; import { vitePreprocess } from '@sveltejs/kit/vite'; /** @type {import('@sveltejs/kit').Config} */ @@ -8,8 +10,23 @@ const config = { preprocess: vitePreprocess(), kit: { - adapter: adapter() + adapter: adapter({ + fallback: 'index.html', + trailingSlash: 'always' + }), + + prerender: { entries: [] } } }; export default config; + +// import adapter from '@sveltejs/adapter-static'; +// export default { +// kit: { +// adapter: adapter({ +// fallback: '200.html' +// }), +// prerender: { entries: [] } +// } +// }; |
