Closed wotermelon closed 5 months ago
src/router/hooks/use-match-route-meta.tsx
const currentRouteMeta = flattenedRoutes.find( (item) => item.key === lastRoute?.pathname || `${item.key}/` === lastRoute?.pathname, ); if (currentRouteMeta) { if (!currentRouteMeta.hideTab) { currentRouteMeta.outlet = children; setMatchRouteMeta(currentRouteMeta); } } else { push(HOMEPAGE); }
lastRoute?.pathname => /article/123 key: '/article/:articleId' !== '/article/123'
导致这种形式的路由会一直跳HOMEPAGE
你可以尝试处理下这个bug
src/router/hooks/use-match-route-meta.tsx
lastRoute?.pathname => /article/123 key: '/article/:articleId' !== '/article/123'
导致这种形式的路由会一直跳HOMEPAGE