devServer: {
host: "0.0.0.0",
port: 8000, // 端口号
https: true, // 允许https接口代理
open: true,
hotOnly: true, // 热更新
proxy: {
"/api/v1": {
target: "https://xxx.xxxx.xx",
changeOrigin: true,
secure: false,
},
}
亲测有用。
https://blog.csdn.net/ProgramarQin/article/details/107576808