我正在测试react-native-router-flux的react-native示例。抽屉在Tabs上工作正常,但是当我尝试使用customNacBar时
当用户单击汉堡菜单图标抽屉时,应打开。
当用户单击汉堡菜单图标抽屉未打开时。
以拉并运行react-native示例为例,尝试使用customNavBar实现抽屉。 react-native-router-flux
<Drawer
hideNavBar
key="drawer"
onExit={() => {
console.log('Drawer closed');
}}
onEnter={() => {
console.log('Drawer opened');
}}
contentComponent={DrawerContent}
drawerImage={MenuIcon}
drawerWidth={300}>
<Scene hideNavBar panHandlers={null}>
<Stack key="customNavBar" hideTabBar headerLayoutPreset="center">
<Scene key="customNavBar1" title="CustomNavBar 1" navBar={CustomNavBar} component={CustomNavBarView} back />
<Scene key="customNavBar2" title="CustomNavBar 2" navBar={CustomNavBar} component={CustomNavBarView} back />
<Scene key="customNavBar3" title="Another CustomNavBar" navBar={CustomNavBar2} component={CustomNavBarView} back />
<Scene key="hiddenNavBar" title="hiddenNavBar" component={CustomNavBarView} hideNavBar={true} back />
</Stack>
</Scene>
</Drawer>