Ant-design-pro: 带参数路由无法匹配

Created on 3 Jul 2020  ·  1Comment  ·  Source: ant-design/ant-design-pro

🐛 bug 描述

带参数路由无法匹配

📷 复现步骤

routes: [
{
    path: '/servers/:id/edit',
    name: server edit',
    hideInMenu: true,
    component: './servers/edit',
 },
...
]

浏览器打开 http://localhost:8000/servers/1/edit 404

🏞 期望结果

进入路由组件

💻 复现代码

© 版本信息

  • Ant Design Pro 版本: [e.g. 5.1.0]
  • umi 版本
  • 浏览器环境
  • 开发环境 [e.g. mac OS]

🚑 其他信息

image
image

🛑 bug

>All comments

好像是 @umijs/plugin-access-layout 插件的问题,换成 @umijs/preset-react 插件就没问题了

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wuyongdec picture wuyongdec  ·  3Comments

gaoqiang19514 picture gaoqiang19514  ·  3Comments

952425340 picture 952425340  ·  3Comments

ghost picture ghost  ·  3Comments

lvzheng0404 picture lvzheng0404  ·  3Comments