-
Notifications
You must be signed in to change notification settings - Fork 3
/
vite.config.ts
32 lines (29 loc) · 989 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
/// <reference types="vitest" />
import { defineConfig, InlineConfig, UserConfig } from 'vite';
import react from '@vitejs/plugin-react';
// https://vite.dev/config/
interface VitestConfigExport extends UserConfig {
test: InlineConfig;
}
export default defineConfig({
plugins: [react()],
resolve: {
alias: [
{ find: '@', replacement: '/src' },
{ find: '@assets', replacement: '/src/assets' },
{ find: '@components', replacement: '/src/components' },
{ find: '@pages', replacement: '/src/pages' },
{ find: '@hooks', replacement: '/src/hooks' },
{ find: '@store', replacement: '/src/store' },
{ find: '@styles', replacement: '/src/styles' },
{ find: '@tests', replacement: '/src/tests' },
{ find: '#types', replacement: '/src/types' },
{ find: '@utils', replacement: '/src/utils' },
],
},
test: {
environment: 'jsdom',
globals: true,
setupFiles: './vitest.setup.ts',
},
} as VitestConfigExport);