canPop property

  1. @override
bool canPop
override

Whether this route can be popped.

A route can be popped if there is at least one active route below it, or if willHandlePopInternally returns true.

When this changes, if the route is visible, the route will rebuild, and any widgets that used ModalRoute.of will be notified.

Implementation

@override
bool get canPop {
  return super.canPop || isNested;
}