'I want to make sure that every time the back key is pressed the first screen is pushed
I can't do this normally with Navigator.push and Navigator.pop for reasons that are hard to explain. I need something like the WillPopScope that returns a function when back button is pressed.
I am implementing a registration process for my app divided into 3 steps: registration with Email provider, data registration (such as name, surname and date of birth), and registration with phone number provider. If the application is interrupted during one of these steps, when it is started again it will not show the start page but will resume from the screen of the last step entered (example: if I register the email and data and stop the app, at the next start it will be shown the phone number registration screen directly). Starting not from the first page, if I cancel the registration process I cannot use the Navigator.pop because the previous pages do not exist.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
