feat: 使用vite-tsconfig-paths插件
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import vueJsx from '@vitejs/plugin-vue-jsx'
|
||||
import { fileURLToPath, URL } from 'node:url'
|
||||
import { defineConfig } from 'vite'
|
||||
import checker from 'vite-plugin-checker'
|
||||
import vueDevTools from 'vite-plugin-vue-devtools'
|
||||
import tsconfigPaths from 'vite-tsconfig-paths'
|
||||
|
||||
// https://vite.dev/config/
|
||||
export default defineConfig({
|
||||
@@ -18,10 +18,6 @@ export default defineConfig({
|
||||
eslint: { useFlatConfig: true, lintCommand: 'eslint "./src/**/*.{ts,tsx,vue}"' },
|
||||
vueTsc: true,
|
||||
}),
|
||||
tsconfigPaths(),
|
||||
],
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': fileURLToPath(new URL('./src', import.meta.url)),
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user