ref 路由生成方式调整为后台生成和去除mock

This commit is contained in:
DaxPay
2024-07-02 16:22:50 +08:00
parent 37ee147249
commit 40dda3d4e4
276 changed files with 1551 additions and 19426 deletions

View File

@@ -1,4 +1,4 @@
import { defineApplicationConfig } from '@vben/vite-config';
import { defineApplicationConfig } from '@vben/vite-config'
export default defineApplicationConfig({
overrides: {
@@ -24,17 +24,19 @@ export default defineApplicationConfig({
// only https
// secure: false
},
'/upload': {
target: 'http://localhost:3300/upload',
'/server': {
target: 'http://localhost:9000',
changeOrigin: true,
ws: true,
rewrite: (path) => path.replace(new RegExp(`^/upload`), ''),
rewrite: (path) => path.replace(new RegExp(`^/server`), ''),
// only https
// secure: false
},
},
open: true, // 项目启动后,自动打开
open: false, // 项目启动后,自动打开
warmup: {
clientFiles: ['./index.html', './src/{views,components}/*'],
},
},
},
});
})