|
|
@@ -1,6 +1,12 @@
|
|
1
|
1
|
import { defineConfig } from 'vite'
|
|
2
|
2
|
import vue from '@vitejs/plugin-vue'
|
|
3
|
3
|
|
|
|
4
|
+import path from 'path'
|
|
|
5
|
+import { fileURLToPath } from 'url'
|
|
|
6
|
+
|
|
|
7
|
+const filename = fileURLToPath(import.meta.url)
|
|
|
8
|
+const dirname = path.dirname(filename)
|
|
|
9
|
+
|
|
4
|
10
|
// https://vitejs.dev/config/
|
|
5
|
11
|
export default defineConfig({
|
|
6
|
12
|
css: {
|
|
|
@@ -14,7 +20,7 @@ export default defineConfig({
|
|
14
|
20
|
plugins: [vue()],
|
|
15
|
21
|
resolve: {
|
|
16
|
22
|
alias: {
|
|
17
|
|
- '@': require('path').resolve(__dirname, 'src'),
|
|
|
23
|
+ '@': path.resolve(dirname, 'src'),
|
|
18
|
24
|
},
|
|
19
|
25
|
},
|
|
20
|
26
|
})
|