sveltekit config tweaks for base url

This commit is contained in:
Yanick Champoux 2022-04-06 20:09:22 -04:00
parent 3a4ad998ad
commit 243a494864
2 changed files with 12 additions and 10 deletions

View File

@ -43,6 +43,7 @@
"rollup-plugin-analyzer": "^4.0.0", "rollup-plugin-analyzer": "^4.0.0",
"svelte-chota": "^1.8.6", "svelte-chota": "^1.8.6",
"svelte-knobby": "^0.3.4", "svelte-knobby": "^0.3.4",
"svelte-moveable": "^0.20.0",
"ts-action": "^11.0.0", "ts-action": "^11.0.0",
"updux": "link:/home/yanick/work/javascript/updux-js/", "updux": "link:/home/yanick/work/javascript/updux-js/",
"webpack": "5" "webpack": "5"

View File

@ -1,18 +1,19 @@
import adapter from "@sveltejs/adapter-static"; import adapter from "@sveltejs/adapter-static";
import analyze from "rollup-plugin-analyzer"; import analyze from "rollup-plugin-analyzer";
const dev = process.env.NODE_ENV === "development";
/** @type {import('@sveltejs/kit').Config} */ /** @type {import('@sveltejs/kit').Config} */
export default { export default {
kit: { kit: {
adapter: adapter(), adapter: adapter({ fallback: "index.html" }),
paths: { base: "/aotds-docks" }, paths: { base: dev ? "" : "/aotds-docks" },
vite: { vite: {
build: { build: {
rollupOptions: { rollupOptions: {
plugins: [analyze()], plugins: [analyze()],
// external: ['updux','@yanick/updeep'] // external: ['updux','@yanick/updeep']
},
},
}, },
},
}, },
},
}; };