pushReplacement<T extends Object?, TO extends Object?> method
Implementation
Future<T?> pushReplacement<T extends Object?, TO extends Object?>(
Widget toPage,
TO? result,
) async {
return await Navigator.pushReplacement<T, TO>(
this,
MaterialPageRoute<T>(
builder: (_) => toPage,
),
result: result,
);
}