pushAll method

Future<void> pushAll(
  1. List<PageRouteInfo> routes, {
  2. OnNavigationFailure? onFailure,
})

Adds the corresponding pages to given routes list to the _pages stack at once

if onFailure callback is provided, navigation errors will be passed to it otherwise they'll be thrown

Implementation

Future<void> pushAll(
  List<PageRouteInfo> routes, {
  OnNavigationFailure? onFailure,
}) {
  assert(routes.isNotEmpty);
  return _findStackScope(routes.first)._pushAll(
    routes,
    onFailure: onFailure,
    notify: true,
  );
}