vue.config.js 662 B

123456789101112131415161718192021222324252627282930
  1. const { defineConfig } = require('@vue/cli-service')
  2. module.exports = defineConfig({
  3. devServer:{
  4. proxy:{
  5. '/api':{
  6. target:'https://m.douban.com/rexxar/api/v2',
  7. changeOrigin:true,
  8. pathRewrite:{
  9. '^/api':''
  10. }
  11. },
  12. '/market':{
  13. target:'https://market.douban.com/api/v2',
  14. changeOrigin:true,
  15. pathRewrite:{
  16. '^/market':''
  17. }
  18. },
  19. '/doubao':{
  20. target:'https://ark.cn-beijing.volces.com/api/v3',
  21. changeOrigin:true,
  22. pathRewrite:{
  23. '^/doubao':''
  24. }
  25. }
  26. },
  27. compress: false
  28. },
  29. transpileDependencies: true
  30. })