27 lines
1.1 KiB
Diff
27 lines
1.1 KiB
Diff
diff --git a/src/exports/vite/index.js b/src/exports/vite/index.js
|
|
index e23cf2b833fc0a04287d34328b97bf64c7916f0d..81b6f30f3a5f2c8d3d0337777e141e549c4a5f98 100644
|
|
--- a/src/exports/vite/index.js
|
|
+++ b/src/exports/vite/index.js
|
|
@@ -473,7 +473,7 @@ Tips:
|
|
// for internal use only. it's published as $app/paths externally
|
|
// we use this alias so that we won't collide with user aliases
|
|
case sveltekit_paths: {
|
|
- const { assets, base } = svelte_config.kit.paths;
|
|
+ const { assets, base, relative } = svelte_config.kit.paths;
|
|
|
|
// use the values defined in `global`, but fall back to hard-coded values
|
|
// for the sake of things like Vitest which may import this module
|
|
@@ -488,10 +488,10 @@ Tips:
|
|
|
|
return dedent`
|
|
export let base = ${s(base)};
|
|
- export let assets = ${assets ? s(assets) : 'base'};
|
|
+ export let assets = ${relative ? "'.' + " : ''}${assets ? s(assets) : 'base'};
|
|
export const app_dir = ${s(kit.appDir)};
|
|
|
|
- export const relative = ${svelte_config.kit.paths.relative};
|
|
+ export const relative = ${relative};
|
|
|
|
const initial = { base, assets };
|
|
|