Replies: 1 comment
-
+1 to this. I would like to be able to tell whether |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Feature Request
add a success callback to
navigate
. Something like:Now, you might think, why not simply write:
This might work for most cases, but sometimes, it won't. For example, when using
usePrompt
.Motivation
In my case, I have a dialog with a form. When clicking on a button on the screen, it opens the dialog with
?dialog=true
search param.When closing the modal, the function
close
will be invoked, and the search param as result will be removed.In order to prevent from users accidentally clicking outside of the dialog while the form is dirty, I have added usePrompt.
The problem is, that while
navigate
has been aborted,dialog.hide
anddialog.remove
have been invoked.Beta Was this translation helpful? Give feedback.
All reactions