Amju
commited on
fix(config): path not defined error (#3)
Browse files* Update vite.config.ts
fixed 'path not defined' error
* fix: add
@types
/node
- package.json +1 -0
- vite.config.ts +2 -1
package.json
CHANGED
@@ -19,6 +19,7 @@
|
|
19 |
"tailwindcss-animate": "^1.0.6"
|
20 |
},
|
21 |
"devDependencies": {
|
|
|
22 |
"@types/react": "^18.0.37",
|
23 |
"@types/react-dom": "^18.0.11",
|
24 |
"@typescript-eslint/eslint-plugin": "^5.59.0",
|
|
|
19 |
"tailwindcss-animate": "^1.0.6"
|
20 |
},
|
21 |
"devDependencies": {
|
22 |
+
"@types/node": "^20.8.0",
|
23 |
"@types/react": "^18.0.37",
|
24 |
"@types/react-dom": "^18.0.11",
|
25 |
"@typescript-eslint/eslint-plugin": "^5.59.0",
|
vite.config.ts
CHANGED
@@ -1,12 +1,13 @@
|
|
1 |
import { defineConfig } from 'vite';
|
2 |
import react from '@vitejs/plugin-react';
|
|
|
3 |
|
4 |
// https://vitejs.dev/config/
|
5 |
export default defineConfig({
|
6 |
plugins: [react()],
|
7 |
resolve: {
|
8 |
alias: {
|
9 |
-
'@':
|
10 |
},
|
11 |
},
|
12 |
});
|
|
|
1 |
import { defineConfig } from 'vite';
|
2 |
import react from '@vitejs/plugin-react';
|
3 |
+
import { resolve } from "path";
|
4 |
|
5 |
// https://vitejs.dev/config/
|
6 |
export default defineConfig({
|
7 |
plugins: [react()],
|
8 |
resolve: {
|
9 |
alias: {
|
10 |
+
'@': resolve(__dirname, './src'),
|
11 |
},
|
12 |
},
|
13 |
});
|