我正在使用react-navigation并尝试通过单击中的选项卡项打开抽屉(使用DrawerNavigator)BottomTabNavigator。
我当前的代码如下所示
export default createBottomTabNavigator({
Dashboard:{
screen:Dashboard,
navigationOptions:{
tabBarLabel:'Dashboard',
tabBarIcon:({tintColor}) => (
<Icon name ="ios-speedometer-outline" color =
{tintColor} size = {24} />
)
}
},
Customers:{
screen:Customers,
navigationOptions:{
tabBarLabel:'Customers',
tabBarIcon:({tintColor}) => (
<Icon name ="ios-people-outline" color =
{tintColor} size = {24} />
)
}
},
Invoice:{
screen:Invoice,
navigationOptions:{
tabBarLabel:'Invoice',
tabBarIcon:({tintColor}) => (
<Icon name ="ios-copy-outline" color =
{tintColor} size = {24} />
)
}
},
TimeTracker:{
screen:TimeTracker,
navigationOptions:{
tabBarLabel:'Timetracker',
tabBarIcon:({tintColor}) => (
<Icon name ="ios-timer-outline" color …Run Code Online (Sandbox Code Playgroud)