feat:增加接口请求方式配置、增加跨域接口访问配置、增加使用案例。

This commit is contained in:
wuyx
2022-10-24 14:49:39 +08:00
parent b433e00429
commit 3a11f41826
5 changed files with 172 additions and 39 deletions

View File

@@ -1,4 +1,17 @@
const { defineConfig } = require('@vue/cli-service')
module.exports = defineConfig({
transpileDependencies: true
})
transpileDependencies: true,
devServer: {
proxy: {
"/api": {
target: "http://111.231.196.214:30001/",
changeOrigin: true,
secure: false,
ws: true,
pathRewrite: {
"^/api": "",
},
},
},
}
})