afterLeave method

  1. @override
void afterLeave(
  1. BuildContext context,
  2. String? from,
  3. String to
)
inherited

This is called after the url and the historyState are updated and this VRouteElement was in the previous route and is NOT in the new route You can't prevent the navigation anymore You can get the new route parameters, and queryParameters

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

@override
void afterLeave(BuildContext context, String? from, String to) =>
    voidAfterLeave(context, from, to);