In my BottomTabNavigator, I have an overview tab. When I click it, it bring the overview tab's initial route. From here, I can click to see more details. This will routes to a different screen. Let's call it (B)
My issue is if I am in this Route/page (B) inside my Overview Tab then I click on a different tab and I go back to Overview it show me Route/page (B) however I want it to display Route/page (A) if I change a tab and come back to it.
How can I do that?
This is my OverviewStack.js
import OverviewStack from "./overviewStack";
import { createStackNavigator } from "react-navigation";
.
.
.
const OverviewStack = createStackNavigator(
{
...OverviewRoutes,
},
{
initialRouteName: "Overview",
resetOnBlur: true,
navigationOptions: ({ navigation }) => ({
...SharedHeader(navigation),
}),
}
);
tabNavigator.js
import { createBottomTabNavigator } from "react-navigation";
.
.
.
export default createBottomTabNavigator(
{
Overview: {
resetOnBlur: true,
screen: OverviewStack,
navigationOptions: {
title: "Home",
},
},
Averages: {
resetOnBlur: true,
screen: TrackStack,
navigationOptions: {
title: "Track",
},
},