1.

How To Use Routing with React Navigation in React Native ?

Answer»

One of the popular libraries for routing and navigation in a React NATIVE application is React Navigation.

This library HELPS solve the problem of navigating between MULTIPLE screens and sharing data between them.

import * as React from 'react';import { NavigationContainer } from '@react-navigation/native';import { createStackNavigator } from '@react-navigation/stack';const Stack = createStackNavigator();const MyStack = () => { return ( <NavigationContainer> <Stack.Navigator> <Stack.Screen name="HOME" component={HomeScreen} options={{ title: 'Welcome' }} /> <Stack.Screen name="Profile" component={ProfileScreen} /> </Stack.Navigator> </NavigationContainer> );};


Discussion

No Comment Found