DEV Community

muneebejazz
muneebejazz

Posted on

React Native

React Navigation v6.x

Installation

1. Install in Expo Project

npm install @react-navigation/native
expo install react-native-screens react-native-safe-area-context
expo install @react-navigation/native-stack
Enter fullscreen mode Exit fullscreen mode

2. Wrap your App.js with NavigationContainer component.

<NavigationContainer>
   // you app code goes here
</NavigationContainer>
Enter fullscreen mode Exit fullscreen mode

3. React Native Stack Navigator

Create Native Stack Navigator

const Stack = createNativeStackNavigator()

Top comments (0)