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
|
import react from '@vitejs/plugin-react';
import { defineConfig } from 'vite';
import { createHtmlPlugin } from 'vite-plugin-html';
import svg from 'vite-plugin-svgr';
import tsconfigPaths from 'vite-tsconfig-paths';
export default defineConfig({
plugins: [
tsconfigPaths(),
react(),
svg({ svgrOptions: { icon: true } }),
createHtmlPlugin({
minify: true,
}),
],
css: {
modules: {
localsConvention: 'camelCaseOnly',
},
},
root: 'src',
build: {
sourcemap: true,
outDir: '../dist',
assetsDir: '.',
},
});
|