pushNamedAndRemoveUntil<T extends Object?> method

Future<T?> pushNamedAndRemoveUntil<T extends Object?>({
  1. required String routeName,
  2. required String removeRouteName,
  3. Object? arguments,
  4. bool rootNavigator = false,
})

Implementation

Future<T?> pushNamedAndRemoveUntil<T extends Object?>({
  required String routeName,
  required String removeRouteName,
  Object? arguments,
  bool rootNavigator = false,
}) {
  return navigator.pushNamedAndRemoveUntil<T>(
    routeName,
    ModalRoute.withName(removeRouteName),
    arguments: arguments,
  );
}