NavKitContext extension

Convenience extensions on BuildContext for common navigation actions.

These mirror the NavKit static methods but can be called directly on the context — useful inside widget build methods where you already have context in scope:

// Instead of:
NavKit.push(context, Routes.detail, arguments: item);

// You can write:
context.navPush(Routes.detail, arguments: item);
context.navPop();
on

Properties

Available on BuildContext, provided by the NavKitContext extension

Returns true if there is a route that can be popped.
no setter

Methods

Available on BuildContext, provided by the NavKitContext extension

Pop the current route.

Available on BuildContext, provided by the NavKitContext extension

Pop until routeName is at the top.

Available on BuildContext, provided by the NavKitContext extension

Push a named route with the default platform transition.

Available on BuildContext, provided by the NavKitContext extension

Push and remove all with the default platform transition.

Available on BuildContext, provided by the NavKitContext extension

Push and remove all with fade.

Available on BuildContext, provided by the NavKitContext extension

Push and remove all with bottom-to-up slide + fade.

Available on BuildContext, provided by the NavKitContext extension

Push with a fully custom NavTransitionType.

Available on BuildContext, provided by the NavKitContext extension

Push replacement with the default platform transition.

Available on BuildContext, provided by the NavKitContext extension

Push replacement with fade.

Available on BuildContext, provided by the NavKitContext extension

Push replacement with bottom-to-up slide + fade.

Available on BuildContext, provided by the NavKitContext extension

Push a widget directly with fade.

Available on BuildContext, provided by the NavKitContext extension

Push a widget directly with bottom-to-up slide + fade.

Available on BuildContext, provided by the NavKitContext extension

Push with a fade animation.

Available on BuildContext, provided by the NavKitContext extension

Push with a slide-only animation.

Available on BuildContext, provided by the NavKitContext extension

Push with a slide + fade animation.

Available on BuildContext, provided by the NavKitContext extension

Push with a bottom-to-up slide + fade animation.