Created
November 6, 2021 05:52
-
-
Save crazy-diya/30247ad487da113cbc1008a87e857f04 to your computer and use it in GitHub Desktop.
Animate Transaction Page to Page flutter Navigator
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Navigator.of(context).push( | |
PageRouteBuilder( | |
transitionDuration: Duration(milliseconds: 1000), | |
pageBuilder: (BuildContext context, | |
Animation<double> animation, | |
Animation<double> secondaryAnimation) { | |
return HomePage(); | |
}, | |
transitionsBuilder: (BuildContext context, | |
Animation<double> animation, | |
Animation<double> secondaryAnimation, | |
Widget child) { | |
return Align( | |
child: FadeTransition( | |
opacity: animation, | |
child: child, | |
), | |
); | |
}, | |
), | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment