import { NavigationContainer } from '@react-navigation/native';
import { createBottomTabNavigator } from '@react-navigation/bottom-tabs';
import USAStateScreen from './screens/USAStateScreen';
import CanadaProvincesScreen from './screens/CanadaProvincesScreen';
const Tab = createBottomTabNavigator();
export default function App() {
return (
<NavigationContainer>
<Tab.Navigator>
<Tab.Screen name="USA" component={USAStateScreen}
options={({ navigation, route }) => ({ title: route.params.name })}/>
<Tab.Screen name="Canada" component={CanadaProvincesScreen}
options={({ navigation, route }) => ({ title: route.params.name })} />
</Tab.Navigator>
</NavigationContainer>
);
}```