chore: 升级vitev5 版本,规定node版本>=18.0.0pnpm版本>=8.6.10 (#738)

This commit is contained in:
xiaoming
2023-11-10 13:16:05 +08:00
committed by GitHub
parent 6e195c8b5c
commit 10e68d681f
18 changed files with 2250 additions and 2298 deletions

View File

@@ -37,13 +37,15 @@ export default ({ command, mode }: ConfigEnv): UserConfigExport => {
},
// 服务端渲染
server: {
// 是否开启 https
https: false,
// 端口号
port: VITE_PORT,
host: "0.0.0.0",
// 本地跨域代理 https://cn.vitejs.dev/config/server-options.html#server-proxy
proxy: {}
proxy: {},
// 预热文件以提前转换和缓存结果,降低启动期间的初始页面加载时长并防止转换瀑布
warmup: {
clientFiles: ["./index.html", "./src/{views,components}/*"]
}
},
plugins: getPluginsList(command, VITE_CDN, VITE_COMPRESSION),
// https://cn.vitejs.dev/config/dep-optimization-options.html#dep-optimization-options