diff options
| author | netop://ウィビ <paul@webb.page> | 2026-04-26 20:18:30 -0700 |
|---|---|---|
| committer | netop://ウィビ <paul@webb.page> | 2026-04-26 20:18:30 -0700 |
| commit | 3c06c95f396b6e911076bc3291d5855ed01b5caa (patch) | |
| tree | 17cd218339c52fbeee93d931303b04a3ff294f8b /svelte.config.js | |
| parent | f059d97ab7f6d74d61139ac698cb871be7cb632e (diff) | |
| download | graphiql-3c06c95f396b6e911076bc3291d5855ed01b5caa.tar.gz graphiql-3c06c95f396b6e911076bc3291d5855ed01b5caa.zip | |
cleanup and ready for launch
Diffstat (limited to 'svelte.config.js')
| -rw-r--r-- | svelte.config.js | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/svelte.config.js b/svelte.config.js index c56f5d3..d5b3f97 100644 --- a/svelte.config.js +++ b/svelte.config.js @@ -1,5 +1,20 @@ + + + +/*** IMPORT ------------------------------------------- ***/ + import { vitePreprocess } from "@sveltejs/vite-plugin-svelte"; +import { sveltePreprocess } from "svelte-preprocess"; + +/*** EXPORT ------------------------------------------- ***/ + +const isPackaging = process.argv[1]?.endsWith("svelte-package.js") + || process.env.npm_lifecycle_event === "package" + || process.env.npm_lifecycle_event === "prepublishOnly" + || process.env.npm_lifecycle_event === "publish"; export default { - preprocess: vitePreprocess() + preprocess: isPackaging + ? [sveltePreprocess({ scss: { silenceDeprecations: ["legacy-js-api"] } })] + : [vitePreprocess()] }; |