From f7dbc127ccfb5cc2e291b3070d06f903c7899821 Mon Sep 17 00:00:00 2001 From: liufumingren Date: Tue, 8 Sep 2026 03:38:19 +0800 Subject: [PATCH] =?UTF-8?q?chore(vite):=20=E5=BC=80=E5=8F=91=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=E5=99=A8=E5=85=81=E8=AE=B8=E6=89=80=E6=9C=89=20Host?= =?UTF-8?q?=20=E8=AE=BF=E9=97=AE=EF=BC=88allowedHosts:=20true=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vite.config.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/vite.config.ts b/vite.config.ts index 0859f58b..de5c2fa6 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -20,6 +20,8 @@ export default defineConfig({ server: { port: 5174, host: '0.0.0.0', + // 允许所有主机访问开发服务器(如 test.wms.com、局域网 IP 等) + allowedHosts: true, proxy: { '/dev-api': { target: 'http://localhost:9528', // Assuming Vue 2 backend is running here, user can change