-
Notifications
You must be signed in to change notification settings - Fork 48
/
vite.config.mts
32 lines (31 loc) · 1.06 KB
/
vite.config.mts
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
import react from '@vitejs/plugin-react-swc'
import { defineConfig } from 'vite'
import { configDefaults } from 'vitest/config'
import path from 'path'
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
resolve: {
alias: {
api: path.resolve(__dirname, 'src/api'),
components: path.resolve(__dirname, 'src/components'),
context: path.resolve(__dirname, 'src/context'),
css: path.resolve(__dirname, 'src/css'),
ducks: path.resolve(__dirname, 'src/ducks'),
factions: path.resolve(__dirname, 'src/factions'),
generic_rules: path.resolve(__dirname, 'src/generic_rules'),
meta: path.resolve(__dirname, 'src/meta'),
store: path.resolve(__dirname, 'src/store'),
tests: path.resolve(__dirname, 'src/tests'),
theme: path.resolve(__dirname, 'src/theme'),
types: path.resolve(__dirname, 'src/types'),
utils: path.resolve(__dirname, 'src/utils'),
// Add more aliases as needed
},
},
test: {
...configDefaults,
environment: 'jsdom',
globals: true,
},
})