diff options
author | 2023-09-05 23:31:15 +0530 | |
---|---|---|
committer | 2023-09-05 23:31:15 +0530 | |
commit | 7d95bd9baaf755239fd7d35e4813861b2dbccf42 (patch) | |
tree | b5dab36627b9152d09629989d56667fbe44061f2 /packages/integrations/svelte/src/index.ts | |
parent | 5126c6a40f88bff66ee5d3c3a21eea8c4a44ce7a (diff) | |
download | astro-7d95bd9baaf755239fd7d35e4813861b2dbccf42.tar.gz astro-7d95bd9baaf755239fd7d35e4813861b2dbccf42.tar.zst astro-7d95bd9baaf755239fd7d35e4813861b2dbccf42.zip |
Allow vite to refer to inlined CSS (#8351)
* fix(client build): keep inlined stylesheets
* add changesets
* appease linter
* eslint: allow variables beginning with an underscore to be unused
* remove eslint-ignore that's no longer needed
* ready for review
Diffstat (limited to 'packages/integrations/svelte/src/index.ts')
-rw-r--r-- | packages/integrations/svelte/src/index.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/integrations/svelte/src/index.ts b/packages/integrations/svelte/src/index.ts index ab87a59b2..a9d4f37c9 100644 --- a/packages/integrations/svelte/src/index.ts +++ b/packages/integrations/svelte/src/index.ts @@ -17,7 +17,8 @@ async function svelteConfigHasPreprocess(root: URL) { for (const file of svelteConfigFiles) { const filePath = fileURLToPath(new URL(file, root)); try { - const config = (await import(filePath)).default; + // Suppress warnings by vite: "The above dynamic import cannot be analyzed by Vite." + const config = (await import(/* @vite-ignore */ filePath)).default; return !!config.preprocess; } catch {} } |