mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-23 23:39:47 +08:00
feat(projects): 引入soybean-admin-tab、去除vite-plugin-svg-icons,用unplugin-icons实现自定义svg的iconify写法、代码优化
This commit is contained in:
@ -3,18 +3,21 @@ import { defineConfig, loadEnv } from 'vite';
|
||||
import { setupVitePlugins, define } from './build';
|
||||
|
||||
export default defineConfig(configEnv => {
|
||||
const viteEnv = loadEnv(configEnv.mode, `.env.${configEnv.mode}`);
|
||||
const viteEnv = loadEnv(configEnv.mode, `.env.${configEnv.mode}`) as ImportMetaEnv;
|
||||
|
||||
const srcPath = fileURLToPath(new URL('./src', import.meta.url));
|
||||
const rootPath = fileURLToPath(new URL('./', import.meta.url));
|
||||
|
||||
return {
|
||||
base: viteEnv.VITE_APP_BASE_URL,
|
||||
base: viteEnv.VITE_BASE_URL,
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': fileURLToPath(new URL('./src', import.meta.url)),
|
||||
'~': fileURLToPath(new URL('./', import.meta.url))
|
||||
'@': srcPath,
|
||||
'~': rootPath
|
||||
}
|
||||
},
|
||||
define,
|
||||
plugins: setupVitePlugins(configEnv),
|
||||
plugins: setupVitePlugins(configEnv, srcPath, viteEnv),
|
||||
css: {
|
||||
preprocessorOptions: {
|
||||
scss: {
|
||||
@ -22,7 +25,6 @@ export default defineConfig(configEnv => {
|
||||
}
|
||||
}
|
||||
},
|
||||
assetsInclude: ['/public/**'],
|
||||
server: {
|
||||
fs: {
|
||||
strict: false
|
||||
|
Reference in New Issue
Block a user