View.on-navigate Behavior

I haven’t been able to find any documentation on the “on-navigate” attribute of a view. Is it like the on-back event but applies to all navigation leaving the view? Or is it on navigating to the view? I tested it out and I am no longer able to navigate away from my view so I suspect it’s the former.

The on-back hook still results in a dismiss() unless some other navigation occurs. Does on-navigate not behave this way? How can I allow the original navigation action, but hook into the event to make some object changes?

Simply end your on-navigate function with return true; and the original navigation will execute as expected

And to confirm, any function specified in the on-navigate attribute of the view will be executed on an attempted forwards navigation (link or navigate.link) or an attempted sideways navigation (navigate.replace or navigate.clear) from that view. It will not execute on a backwards navigation.