Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop state / restart screen #25

Open
Tolriq opened this issue Oct 25, 2021 · 1 comment
Open

Drop state / restart screen #25

Tolriq opened this issue Oct 25, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@Tolriq
Copy link

Tolriq commented Oct 25, 2021

This is probably a feature request unless I missed something and certainly not a vital one.

Is there a way to restart a screen fresh?

For example in a tab screen I start a nested navigation, when pressing the same tab button I'd like to return to the home of that tab but in a fresh state (so not scrolled for example).
I can have the screen provide their nested navigator via an interface and for example use popUntilRoot but as expected the root screen is restored in it's previous state (normal wanted default behavior).

In some cases I'd like to be able to restart that screen fresh

@adrielcafe adrielcafe added the enhancement New feature or request label Dec 16, 2021
@Syer10
Copy link
Contributor

Syer10 commented Oct 24, 2022

On my fork of Voyager I made Navigator.dispose public, maybe add a DisposableEffect that uses Navigator.dispose on the current screen?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants