mirror of
https://github.com/zhigang1992/react-navigation.git
synced 2026-03-26 09:14:22 +08:00
Fix TabRouter to support shorthand route config
This commit is contained in:
@@ -30,8 +30,9 @@ export default (routeConfigs, config = {}) => {
|
||||
paths[routeName] =
|
||||
typeof routeConfig.path === 'string' ? routeConfig.path : routeName;
|
||||
tabRouters[routeName] = null;
|
||||
if (routeConfig.screen && routeConfig.screen.router) {
|
||||
tabRouters[routeName] = routeConfig.screen.router;
|
||||
const screen = getScreenForRouteName(routeConfigs, routeName);
|
||||
if (screen.router) {
|
||||
tabRouters[routeName] = screen.router;
|
||||
}
|
||||
});
|
||||
if (initialRouteIndex === -1) {
|
||||
|
||||
Reference in New Issue
Block a user