toAndRemoveUntil<T extends Object?> method
Find the page with given routeName and then remove all the previous routes
until meeting the route with defined route name untilRouteName
.
If no route name is given (untilRouteName
is null) , all routes will be
removed except the new page route.
It is similar to _navigate.toNamedAndRemoveUntil
method.
Implementation
Future<T?> toAndRemoveUntil<T extends Object?>(
String newRouteName, {
String? untilRouteName,
Object? arguments,
Map<String, String>? queryParams,
bool fullscreenDialog = false,
bool maintainState = true,
}) {
return _navigationBuilder.toAndRemoveUntil<T>(
newRouteName,
untilRouteName: untilRouteName,
arguments: arguments,
queryParams: queryParams,
fullscreenDialog: fullscreenDialog,
maintainState: maintainState,
);
}