push<T extends Object?> method
Navigates to a new route.
Example:
context.push(MyPage());
Implementation
Future<T?> push<T extends Object?>(Widget route) {
return Navigator.of(this).push<T>(
MaterialPageRoute(builder: (_) => route),
);
}