123456789101112131415161718192021222324252627282930313233
  1. // ref: https://umijs.org/config/
  2. export default {
  3. history: 'hash',
  4. treeShaking: true,
  5. proxy: {
  6. "/api": {
  7. "target": "http://127.0.0.1:8088/",
  8. "changeOrigin": true,
  9. // "pathRewrite": { "^/api" : "" }
  10. }
  11. },
  12. plugins: [
  13. // ref: https://umijs.org/plugin/umi-plugin-react.html
  14. ['umi-plugin-react', {
  15. antd: true,
  16. dva: true,
  17. dynamicImport: { webpackChunkName: true },
  18. title: 'miniapp-service',
  19. dll: false,
  20. routes: {
  21. exclude: [
  22. /models\//,
  23. /services\//,
  24. /model\.(t|j)sx?$/,
  25. /service\.(t|j)sx?$/,
  26. /components\//,
  27. ],
  28. },
  29. }],
  30. ],
  31. }