-
Notifications
You must be signed in to change notification settings - Fork 4
/
vite.config.ts
42 lines (41 loc) · 981 Bytes
/
vite.config.ts
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
/* eslint-disable @typescript-eslint/no-unsafe-call */
import { resolve } from 'path';
import { defineConfig } from 'vite';
import notifier from 'vite-plugin-notifier';
import solidPlugin from 'vite-plugin-solid';
import { visualizer } from 'rollup-plugin-visualizer';
import checker from 'vite-plugin-checker';
export default defineConfig({
optimizeDeps: {
exclude: [
],
},
plugins: [
{
enforce: 'pre',
},
solidPlugin(),
notifier(),
checker({
typescript: true,
eslint: {
files: ['./src'],
extensions: ['.ts', '.tsx'],
},
enableBuild: false,
}),
],
build: {
assetsDir: '_assets',
sourcemap: process.env.ANALYZE && true,
rollupOptions: {
plugins: [
process.env.ANALYZE && visualizer({
filename: resolve(__dirname, 'dist/stats.html'),
template: 'treemap', // sunburst|treemap|network
sourcemap: true,
}),
],
},
},
});