proxy.ts 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * @Author: your name
  3. * @Date: 2021-09-03 14:28:27
  4. * @LastEditTime: 2021-10-27 14:55:41
  5. * @LastEditors: Please set LastEditors
  6. * @Description: In User Settings Edit
  7. * @FilePath: /MedicalWisdomCheckSys/config/proxy.ts
  8. */
  9. /**
  10. * 在生产环境 代理是无法生效的,所以这里没有生产环境的配置
  11. * -------------------------------
  12. * The agent cannot take effect in the production environment
  13. * so there is no configuration of the production environment
  14. * For details, please see
  15. * https://pro.ant.design/docs/deploy
  16. */
  17. export default {
  18. dev: {
  19. '/api': {
  20. target: 'http://112.124.59.133:8083/',
  21. changeOrigin: true,
  22. pathRewrite: { '^/api': '' },
  23. },
  24. },
  25. mock: {
  26. '/api/': {
  27. target: 'http://localhost:8000',
  28. changeOrigin: true,
  29. pathRewrite: { '^': '' },
  30. },
  31. },
  32. test: {
  33. '/api/': {
  34. target: 'https://preview.pro.ant.design',
  35. changeOrigin: true,
  36. pathRewrite: { '^': '' },
  37. },
  38. },
  39. pre: {
  40. '/api/': {
  41. target: 'your pre url',
  42. changeOrigin: true,
  43. pathRewrite: { '^': '' },
  44. },
  45. },
  46. };