generated from Sup2point0/svelte-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
svelte.config.js
54 lines (47 loc) · 1.06 KB
/
svelte.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import adapter from "@sveltejs/adapter-static";
import { sveltePreprocess } from "svelte-preprocess";
import { mdsvex } from "mdsvex";
const config = {
kit: {
adapter: adapter({
pages: "build",
assets: "build",
fallback: "404.html",
precompress: false,
strict: true,
}),
paths: {
base: process.argv.includes("dev") ? "" : process.env.BASE_PATH
},
alias: {
"#src": "./src/",
"#parts": "./src/parts",
"#styles": "./src/styles",
"#scripts": "./src/scripts",
},
prerender: {
handleHttpError: "warn",
},
},
preprocess: [
mdsvex({
extensions: [".svelte", ".md", ".svx"],
}),
sveltePreprocess({
scss: {
prependData: `
@use './src/styles/mixins/fonts' as *;
@use './src/styles/mixins/ui' as *;
`,
}
}),
],
extensions: [".svelte", ".md", ".svx"],
onwarn: (warning, handler) => {
if (warning.code === "css-unused-selector") {
return;
}
handler(warning);
},
};
export default config;