push<T extends Object?> method
Push a location onto the page stack.
See also:
- pushReplacement which replaces the top-most page of the page stack and always uses a new page key.
- replace which replaces the top-most page of the page stack but treats it as the same page. The page key will be reused. This will preserve the state and not run any page animation.
Implementation
Future<T?> push<T extends Object?>(String location, {Object? extra}) =>
GoRouter.of(this).push<T>(location, extra: extra);