Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

约定路由 404.js 没有生效 #4437

Closed
ouyangfan opened this issue Apr 12, 2020 · 4 comments
Closed

约定路由 404.js 没有生效 #4437

ouyangfan opened this issue Apr 12, 2020 · 4 comments

Comments

@ouyangfan
Copy link

ouyangfan commented Apr 12, 2020

  • Umi Version: 3.1.1
@ycjcl868
Copy link
Contributor

404 路由是有,在 /404 路由上,没垫底 404 路由

@Lizhooh
Copy link

Lizhooh commented Jul 12, 2020

同样的问题,生成如下代码:

const routes = [
  {
    "path": "/",
    "component": require('@/layouts/index.tsx').default,
    "routes": [
      {
        "path": "/404",
        "exact": true,
        "component": require('@/pages/404.tsx').default
      },
      {
        "path": "/",
        "exact": true,
        "component": require('@/pages/index.tsx').default
      },
      {
        "path": "/user",
        "exact": true,
        "component": require('@/pages/user.tsx').default
      }
    ]
  }
];

@handycode
Copy link

参考上边的 pr 增加自定义插件吧
#5092 (comment)

@xiaohuoni
Copy link
Member

相同问题#5092

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants