mirror of
https://github.com/un-pany/v3-admin-vite.git
synced 2025-04-20 10:59:21 +08:00
perf: 优化预热常用文件功能
This commit is contained in:
parent
5aa09b05db
commit
c643b410ef
@ -34,7 +34,7 @@ export default defineConfig(({ mode }) => {
|
||||
// 端口被占用时,是否直接退出
|
||||
strictPort: false,
|
||||
// 是否自动打开浏览器
|
||||
open: false,
|
||||
open: true,
|
||||
// 反向代理
|
||||
proxy: {
|
||||
"/api/v1": {
|
||||
@ -49,7 +49,11 @@ export default defineConfig(({ mode }) => {
|
||||
cors: true,
|
||||
// 预热常用文件,提高初始页面加载速度
|
||||
warmup: {
|
||||
clientFiles: ["./src/layouts/**/*.vue"]
|
||||
clientFiles: [
|
||||
"./src/layouts/**/*.*",
|
||||
"./src/pinia/**/*.*",
|
||||
"./src/router/**/*.*"
|
||||
]
|
||||
}
|
||||
},
|
||||
// 构建配置
|
||||
|
Loading…
x
Reference in New Issue
Block a user