canPopOf static method

bool? canPopOf(
  1. BuildContext context
)

Returns ModalRoute.canPop for the modal route most closely associated with the given context.

Returns null if the given context is not associated with a modal route.

Use of this method will cause the given context to rebuild any time that the ModalRoute.canPop property of the ancestor _ModalScopeStatus changes.

Implementation

static bool? canPopOf(BuildContext context) => _of(context, _ModalRouteAspect.canPop)?.canPop;