onBackPressed property

VoidCallback? onBackPressed
final

The action to perform when pressing the back button.

By default it calls Navigator.pop

Implementation

final VoidCallback? onBackPressed;