[flutter] navigator pop() with return data

0

Navigator.push()

onTap: () => Navigator.push(
        context,
        MaterialPageRoute(
            builder: (context) =>
                EventNotificationSettingPage(notificationMinute)),
      ).then((onValue) => print(onValue))),

Navigator.pop()

onTap: () => Navigator.pop(context, 'return value :)'),

🍯Tip

πŸ‘‡ better than
.then((onValue) => print())) -> .then(print)

onTap: () => Navigator.push(
        context,
        MaterialPageRoute(
            builder: (context) =>
                EventNotificationSettingPage(notificationMinute)),
      ).then(print),
profile
𝙸 πšŠπš– 𝚊 πšŒπšžπš›πš’πš˜πšžπšœ πšπšŽπšŸπšŽπš•πš˜πš™πšŽπš› πš πš‘πš˜ πšŽπš—πš“πš˜πš’πšœ πšπšŽπšπš’πš—πš’πš—πš 𝚊 πš™πš›πš˜πš‹πš•πšŽπš–. πŸ‡°πŸ‡·πŸ‘©πŸ»β€πŸ’»

0개의 λŒ“κΈ€