1.添加proxy.config.json文件

angular6开发环境代理设置

2.启动项目

ng s --proxy-config proxy.config.json

3.常见问题--使用错误命令

命令1:npm start  --proxy proxy.config.json

angular6开发环境代理设置

npm WARN invalid config proxy="proxy.config.json"

npm WARN invalid config Must be a full url with 'http://'

 

命令2:npm start  --proxy-config proxy.config.json

angular6开发环境代理设置

'proxy.config.json' could not be found in workspace

相关文章:

  • 2021-12-25
  • 2021-10-13
  • 2021-04-25
  • 2021-11-17
  • 2021-07-25
  • 2022-01-01
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-02
  • 2021-04-23
  • 2021-11-10
  • 2021-07-22
  • 2022-12-23
  • 2021-11-14
相关资源
相似解决方案