当我将登录页面传递到我家时,我有一个开关导航器。如果我不单击底部选项卡,我的抽屉将无法工作并发送错误,则我将获得一个抽屉和底部选项卡导航器
const AppTabNavigator = createBottomTabNavigator({
HomeScreen: Home,
SettingsScreen: setting
})
const Draw = createDrawerNavigator({
Home: Home,
Draw: AppTabNavigator
})
const Auth = createStackNavigator({
Login: login,
Home: Home,
Settings: setting,
})
const SwitchNavigator = createSwitchNavigator({
Auth: Auth,
App: Draw,
})
const AppContainer = createAppContainer(SwitchNavigator)
答案 0 :(得分:0)
对于正确的反应导航层次结构,您应该遵循本教程。
https://medium.com/async-la/react-navigation-stacks-tabs-and-drawers-oh-my-92edd606e4db