navigateToPageWithReplace<T> method
Implementation
Future<T> navigateToPageWithReplace<T>(Widget destination, {Object? argument}) async {
return await _navigatorKey.currentState?.pushReplacement(CupertinoPageRoute(
builder: (context) => destination,
settings: RouteSettings(
name: destination.runtimeType.toString(), arguments: argument)));
}