pushAndRemoveUntil<T> method
navigates to a new pages and remove until
transitionDuration
is ignored when transition is equals to Transition.material or Transition.cupertino
backGestureEnabled
not works on Android if transition is Transition.material
Implementation
Future<T?> pushAndRemoveUntil<T>(
Widget page, {
bool Function(Route<dynamic>)? predicate,
Object? arguments,
bool backGestureEnabled = true,
bool maintainState = true,
bool fullscreenDialog = false,
Transition? transition,
Duration? transitionDuration,
}) {
return _navigator.pushAndRemoveUntil<T>(
getRoute(
page,
arguments: arguments,
maintainState: maintainState,
fullscreenDialog: fullscreenDialog,
transition: transition,
transitionDuration: transitionDuration,
backGestureEnabled: backGestureEnabled,
),
predicate ?? (_) => false,
);
}