fix: 开放前端项目IP访问

解决控制台提示 Network: use --host to expose,且无法通过 127.0.0.1 等 IP 访问的问题
This commit is contained in:
Charles7c 2023-10-31 20:24:29 +08:00
parent e9ee6cb1f5
commit 22a291d4cf

View File

@ -6,7 +6,7 @@
"author": "Charles7c",
"license": "Apache-2.0",
"scripts": {
"dev": "vite --config ./config/vite.config.dev.ts",
"dev": "vite --host --config ./config/vite.config.dev.ts",
"build": "vue-tsc --noEmit && vite build --config ./config/vite.config.prod.ts",
"report": "cross-env REPORT=true npm run build",
"preview": "npm run build && vite preview --host",