config/config.js
proxy: { ‘/api‘: { target: ‘http://localhost:8080/santa‘, changeOrigin: true, }, },
浏览器访问地址:
http://localhost:8000//api/login/account
请求服务端访问的地址:
http://localhost:8080/santa/api/login/account
原文:https://www.cnblogs.com/xiaoyutongxue/p/11409579.html