-
Notifications
You must be signed in to change notification settings - Fork 2
/
svelte.config.js
40 lines (36 loc) · 1.01 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
import adapter from '@sveltejs/adapter-static';
import preprocess from 'svelte-preprocess';
import { mdsvex } from 'mdsvex';
import { config as mdsvexConfig } from './mdsvex.config.js';
import { defineConfig } from "vite";
import compress from "vite-plugin-compression";
import { viteSingleFile } from "vite-plugin-singlefile";
/** @type {import('@sveltejs/kit').Config} */
const config = {
// Consult https://github.com/sveltejs/svelte-preprocess
// for more information about preprocessors
extensions: [".svelte", ...mdsvexConfig.extensions],
preprocess: [preprocess(), mdsvex(mdsvexConfig)],
kit: {
adapter: adapter(),
vite: defineConfig({
plugins: [
compress({ algorithm: "brotliCompress" }),
viteSingleFile()
],
build: {
minify: "esbuild",
assetsInlineLimit: 100000000,
chunkSizeWarningLimit: 100000000,
brotliSize: false,
rollupOptions: {
inlineDynamicImports: true,
output: {
manualChunks: () => "app.js",
},
},
}
})
}
};
export default config;