maintainState property
Whether the route should remain in memory when it is inactive.
If this is true, then the route is maintained, so that any futures it is holding from the next route will properly resolve when the next route pops. If this is not necessary, this can be set to false to allow the framework to entirely discard the route's widget hierarchy when it is not visible.
Implementation
final bool maintainState;