forked from kakao-tech-campus-2nd-step3/Team18_FE
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vite.config.ts
32 lines (30 loc) · 1.29 KB
/
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 } from 'vite';
import { resolve } from 'path';
import react from '@vitejs/plugin-react';
import svgr from 'vite-plugin-svgr';
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react({ jsxImportSource: '@emotion/react' }), svgr()],
test: {
globals: true,
environment: 'jsdom',
setupFiles: './src/__test__/setup.ts',
},
resolve: {
alias: [
{ find: '@', replacement: resolve(__dirname, 'src') },
{ find: '@pages', replacement: resolve(__dirname, 'src/pages') },
{ find: '@apis', replacement: resolve(__dirname, 'src/apis') },
{ find: '@assets', replacement: resolve(__dirname, 'src/assets') },
{ find: '@components', replacement: resolve(__dirname, 'src/components') },
{ find: '@store', replacement: resolve(__dirname, 'src/store') },
{ find: '@features', replacement: resolve(__dirname, 'src/features') },
{ find: '@hooks', replacement: resolve(__dirname, 'src/hooks') },
{ find: '@mocks', replacement: resolve(__dirname, 'src/mocks') },
{ find: '@routes', replacement: resolve(__dirname, 'src/routes') },
{ find: '@utils', replacement: resolve(__dirname, 'src/utils') },
{ find: '@types', replacement: resolve(__dirname, 'src/types') },
],
},
});