angular 后台代理的问题

Https代理

“/public”: {
“target”: “https://www.XXXX.com”,
“https”: true,
“secure”:false
}
以上的secure属性,如果安全证书是没有认证的,则应将secure设置为false

wss 代理

“/ws”: {
“target”: “https://127.0.0.1/XXX/ws”,
“https”: true,
“secure”:false,
“ws”:true,
“changeOrigin”: true
}

angular 中是webpack打包的,如有关于代理的详细问题,可查看Webpack–devserver

猜你喜欢

转载自blog.csdn.net/dandan2810/article/details/106343694
今日推荐