Answers for "how to add a screen but not show it in the drawer"

0

how to add a screen but not show it in the drawer

const Drawer = createDrawerNavigator();

const MyDrawer = () => {
  return(
    <Drawer.Navigator initialRouteName="Test">
      <Drawer.Screen name="Test" component={Test}/>
      <Drawer.Screen name="Menu" component={Menu}/>
    </Drawer.Navigator>
  );
}

const AppStack = createStackNavigator();

const MyStack = () => {
  return(
    <AppStack.Navigator initialRouteName="Drawer">
      <AppStack.Screen name="Drawer" component={MyDrawer}/>
      <AppStack.Screen name="Dish Detail" component={DishDetail} />
    </AppStack.Navigator>
  );
}
Posted by: Guest on May-29-2021

Code answers related to "how to add a screen but not show it in the drawer"

Browse Popular Code Answers by Language