Missing important feature from react navigation for nested navigators. #368
mauricedoepke
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In react navigation the initialRouteName for nested navigators is ignored, when directly navigating to it.
See: https://reactnavigation.org/docs/nesting-navigators/#rendering-initial-route-defined-in-the-navigator
This becomes a problem when e.g. nesting Stacks inside tabs. When I e.g. have a home tab and and a settings tab and directly link from home to settings/membership via a clickable link, the settings/index route is ignored as a initialRouteName and neither using the back button nor clicking the tab again will be able to make the settins/index route visible.
As described in the link above, react navigation has the
initial: false
param that one can use to circumvent this problem.But from expo-router this param can apparently not be accessed yet.
This means in such cases one still has to use the navigate method from react-navigation.
Beta Was this translation helpful? Give feedback.
All reactions