You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i've been asking for a reset for a long time now, been one of the top request in the repo expo-router. (expo/router#495)
i just saw the new dismiss/dismissAll function except they don't really fit the usage.with the potential flow and redirection, knowing the count is quite impossible and really not optimal for a reset.
dismissAll is nice too but the scenario would be in most cases.
dismissAll() to go back to start
router.push/replace to the screen you actually want the user to be
meaning visually it would create a really weird experience since the screen will start to navigate to the first screen while actually receiving instruction to navigate/replace to an other screen.
would it be possible to have a params on dismissAll to specify a screen to go to at the end or to stop at if encounter in the stack?
or something to reset the history nav while navigating to the specific screen i'd like. (useful in auth scenario for example)
EDIT:
After some testing, it looks like doing :
router.dissmissAll();
router.push("my-new-path")
on ios it look "smooth" and clean with no weird behavior, still need to check if on older android phone, it still looks good but that at least solve some issues.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
i've been asking for a reset for a long time now, been one of the top request in the repo expo-router. (expo/router#495)
i just saw the new dismiss/dismissAll function except they don't really fit the usage.with the potential flow and redirection, knowing the count is quite impossible and really not optimal for a reset.
dismissAll is nice too but the scenario would be in most cases.
meaning visually it would create a really weird experience since the screen will start to navigate to the first screen while actually receiving instruction to navigate/replace to an other screen.
would it be possible to have a params on dismissAll to specify a screen to go to at the end or to stop at if encounter in the stack?
or something to reset the history nav while navigating to the specific screen i'd like. (useful in auth scenario for example)
EDIT:
After some testing, it looks like doing :
on ios it look "smooth" and clean with no weird behavior, still need to check if on older android phone, it still looks good but that at least solve some issues.
Beta Was this translation helpful? Give feedback.
All reactions