-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvite.config.ts
More file actions
30 lines (29 loc) · 834 Bytes
/
vite.config.ts
File metadata and controls
30 lines (29 loc) · 834 Bytes
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
/* eslint-disable unicorn/prefer-module */
/* eslint-disable unicorn/prefer-node-protocol */
import { svelte } from '@sveltejs/vite-plugin-svelte';
import path from 'path';
import { defineConfig } from 'vite';
export default defineConfig({
plugins: [svelte()],
build: {
target: 'esnext',
sourcemap: false,
minify: true,
cssMinify: true,
copyPublicDir: true,
emptyOutDir: true,
outDir: 'docs',
chunkSizeWarningLimit: 1500,
assetsInlineLimit: 0
},
base: process.env.NODE_ENV === 'production' ? '/csg-builder' : '',
resolve: {
alias: {
$components: path.resolve(__dirname, './src/components'),
$lib: path.resolve(__dirname, './src/lib'),
$stores: path.resolve(__dirname, './src/stores'),
$types: path.resolve(__dirname, './src/types'),
$projects: path.resolve(__dirname, './projects')
}
}
});