beforeUpdate property

Future<void> Function(VRedirector vRedirector) beforeUpdate
final

This is called before the url is updated, if this VRouteElement is in the previous route AND in the new route

Use vRedirector if you want to redirect or stop the navigation. DO NOT use VRouter methods to redirect. vRedirector also has information about the route you leave and the route you go to

Note that you should consider the navigation cycle to handle this precisely, see https://vrouter.dev/guide/Advanced/Navigation%20Control/The%20Navigation%20Cycle

Also see:

Implementation

final Future<void> Function(VRedirector vRedirector) beforeUpdate;