diff --git a/Taskfile.yaml b/Taskfile.yaml index e126acd..a2f2171 100644 --- a/Taskfile.yaml +++ b/Taskfile.yaml @@ -6,6 +6,9 @@ vars: GREETING: Hello, World! tasks: + build: + cmds: + - vite build update-game: cmds: - node src/scripts/updateUsers.js diff --git a/package.json b/package.json index 50b83f3..7077450 100644 --- a/package.json +++ b/package.json @@ -35,6 +35,7 @@ "type": "module", "dependencies": { "@sveltejs/adapter-node": "^4.0.1", + "@sveltejs/adapter-static": "^3.0.1", "@vincjo/datatables": "^1.14.4", "beercss": "^3.4.13", "better-sqlite3": "^9.3.0", diff --git a/src/routes/+layout.js b/src/routes/+layout.js new file mode 100644 index 0000000..189f71e --- /dev/null +++ b/src/routes/+layout.js @@ -0,0 +1 @@ +export const prerender = true; diff --git a/svelte.config.js b/svelte.config.js index 6bfb3c4..3887b06 100644 --- a/svelte.config.js +++ b/svelte.config.js @@ -1,10 +1,12 @@ -import adapter from '@sveltejs/adapter-node'; +import adapter from '@sveltejs/adapter-static'; /** @type {import('@sveltejs/kit').Config} */ const config = { - kit: { - adapter: adapter() - } + kit: { + adapter: adapter({ + fallback: '/index.html', + }), + }, }; export default config;