Advertisement
Guest User

Untitled

a guest
Aug 19th, 2019
203
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. onGenerateRoute: (settings) {
  2. // If you push the PassArguments route
  3. if (settings.name == PassArgumentsScreen.routeName) {
  4. // Cast the arguments to the correct type: ScreenArguments.
  5. final ScreenArguments args = settings.arguments;
  6.  
  7. // Then, extract the required data from the arguments and
  8. // pass the data to the correct screen.
  9. return MaterialPageRoute(
  10. builder: (context) {
  11. return PassArgumentsScreen(
  12. title: args.title,
  13. message: args.message,
  14. );
  15. },
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement