Answers for "flutter Navigator.of(context).push to page"

16

navigator push flutter

// Within the `FirstRoute` widget
onPressed: () {
  Navigator.push(
    context,
    MaterialPageRoute(builder: (context) => SecondRoute()),
  );
}
Posted by: Guest on March-25-2020
0

navigator push flutter

// Within the SecondRoute widget
onPressed: () {
  Navigator.pop(context);
}
Posted by: Guest on March-01-2021

Code answers related to "flutter Navigator.of(context).push to page"

Browse Popular Code Answers by Language