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

Functionality to control route changes #1824

Closed
komakurae opened this issue Jan 2, 2024 · 0 comments
Closed

Functionality to control route changes #1824

komakurae opened this issue Jan 2, 2024 · 0 comments

Comments

@komakurae
Copy link

Currently, as far as I understood, there is no workaround to control when route is being popped or pushed or any other changes. For now it's only possible to know whether it has been popped or pushed etc.
What I actually need to do is to show dialog, when user tries to go to another screen with unsaved data, preventing the user from changing current route.

For now I can see only one solution - add PopScope... BUT for WEB its the issue

The problem here is to control back OR refresh button being pressed (html.BeforeUnloadEvent works only for refresh) + PopScope doens't work for navigateTo

If someone implemented such thing your help would be appreciated. Or if there is a solution with auto_route I think it would be nice to add it to examples.

@komakurae komakurae closed this as not planned Won't fix, can't repro, duplicate, stale Jan 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant