Skip to content

Instantly share code, notes, and snippets.

@diegoveloper
Created July 30, 2018 20:08
Show Gist options
  • Save diegoveloper/ff088a2f190faef310ddef364fc5330e to your computer and use it in GitHub Desktop.
Save diegoveloper/ff088a2f190faef310ddef364fc5330e to your computer and use it in GitHub Desktop.
Navigator.of(context).push(
PageRouteBuilder<Null>(
pageBuilder: (BuildContext context, Animation<double> animation,
Animation<double> secondaryAnimation) {
return AnimatedBuilder(
animation: animation,
builder: (BuildContext context, Widget child) {
return Opacity(
opacity: animation.value,
child: page,
);
});
},
transitionDuration: Duration(milliseconds: 600)),
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment