Skip to content

Instantly share code, notes, and snippets.

@ijoschek
Last active April 7, 2019 07:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ijoschek/aea8e84a9020c9204611fe6260e15636 to your computer and use it in GitHub Desktop.
Save ijoschek/aea8e84a9020c9204611fe6260e15636 to your computer and use it in GitHub Desktop.
flutter_nav_tut
// ...
class _MainPageState extends State<MainPage> {
// ...
@override
Widget build(BuildContext context) {
return Scaffold(
// ...
drawer: Drawer(
child: ListView(
children: <Widget>[
// ...
ListTile(
title: Text('Routed Navigation'),
trailing: Icon(Icons.arrow_forward),
onTap: () {
Navigator.of(context).pop();
Navigator.pushNamed(context, '/newPage');
},
),
// Here will be some Code
],
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment