proxy.js 767 B

123456789101112131415161718192021222324252627282930313233343536
  1. /**
  2. * 在生产环境 代理是无法生效的,所以这里没有生产环境的配置
  3. * The agent cannot take effect in the production environment
  4. * so there is no configuration of the production environment
  5. * For details, please see
  6. * https://pro.ant.design/docs/deploy
  7. */
  8. export default {
  9. dev: {
  10. '/Bug/api': {
  11. target: 'http://localhost:8090/',
  12. changeOrigin: true,
  13. pathRewrite: {
  14. '^/Bug/api': '/Bug/api',
  15. },
  16. }
  17. },
  18. test: {
  19. '/api/': {
  20. target: 'https://preview.pro.ant.design',
  21. changeOrigin: true,
  22. pathRewrite: {
  23. '^': '',
  24. },
  25. },
  26. },
  27. pre: {
  28. '/api/': {
  29. target: 'your pre url',
  30. changeOrigin: true,
  31. pathRewrite: {
  32. '^': '',
  33. },
  34. },
  35. },
  36. };