flutter push vs pushreplacement code example
Example: flutter navigation pushreplacement
void _completeLogin() {
Navigator.pushReplacement(
context, MaterialPageRoute(builder: (BuildContext context) => MyHomePage()));
}
void _completeLogin() {
Navigator.pushReplacement(
context, MaterialPageRoute(builder: (BuildContext context) => MyHomePage()));
}