AutoRoute provides an easy way to declare custom transitions between pages. Just add your transition to the transitionsBuilder
field of your route
...
CustomRoute(
path: '',
page: BooksPage,
transitionsBuilder: SlideTransition(
position: Tween<Offset>(
begin: const Offset(0.0, -1.0),
end: Offset.zero,
).animate(animation),
child: child,
);
)
...
...
CustomRoute(
path: '',
page: BooksPage,
transitionsBuilder: TransitionsBuilders.slideTop
)
...
CustomRoute
and leave transitionsBuilder to be empty