vue 设置代理报错;occurred while trying to proxy request xxx
                                                            生活随笔
收集整理的這篇文章主要介紹了
                                vue 设置代理报错;occurred while trying to proxy request xxx
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.                        
                                報錯:
 [HPM] Error occurred while trying to proxy request /oauth/validate from localhost:8080 to localhost:8081 (ENOTFOUND) (https://nodejs.org/api/errors.html#errors_common_system_errors)
設置代理:
'/xxxxx': {target:"localhost:8081",changeOrigin: true, //可否跨域pathRewrite: {'^/xxxxx': '' //重寫接口,去掉/paas}}
 代理要是完整的url, http://localhost:8081, http 不能少。
總結
以上是生活随笔為你收集整理的vue 设置代理报错;occurred while trying to proxy request xxx的全部內容,希望文章能夠幫你解決所遇到的問題。
 
                            
                        - 上一篇: src-d/gogit 使用
- 下一篇: 谷歌 PaLM 2训练所用文本数据量是初
