修复API地址配置:localhost改为192.168.3.200服务器IP
This commit is contained in:
@@ -2,6 +2,6 @@
|
|||||||
ENV = 'development'
|
ENV = 'development'
|
||||||
|
|
||||||
# 本地环境接口地址
|
# 本地环境接口地址
|
||||||
# VITE_API_URL = 'http://192.168.3.200:8808/'
|
VITE_API_URL = 'http://192.168.3.200:8808/'
|
||||||
VITE_API_URL = 'http://localhost:8808/'
|
# VITE_API_URL = 'http://localhost:8808/'
|
||||||
|
|
||||||
|
|||||||
@@ -54,8 +54,7 @@ const viteConfig = defineConfig((mode: ConfigEnv) => {
|
|||||||
// },
|
// },
|
||||||
proxy: {
|
proxy: {
|
||||||
'/api': {
|
'/api': {
|
||||||
// target: 'http://192.168.3.200:8808',
|
target: 'http://192.168.3.200:8808',
|
||||||
target: 'http://localhost:8808',
|
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
rewrite: (path) => path.replace(/^\/api/, '/api'),
|
rewrite: (path) => path.replace(/^\/api/, '/api'),
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user