vue.config.js 373 B

12345678910111213141516
  1. module.exports = {
  2. productionSourceMap: false,
  3. publicPath: "./",
  4. devServer: {
  5. proxy: { //配置跨域
  6. '/api': {
  7. target: 'https://yuehe.hellevil.com/', //这里后台的地址模拟的;应该填写你们真实的后台接口
  8. changOrigin: true, //允许跨域
  9. pathRewrite: {
  10. '^/api': ''
  11. }
  12. },
  13. }
  14. },
  15. };