kalismeras61 / flutter_page_transition

This is Flutter Page Transition Package
BSD 2-Clause "Simplified" License
471 stars 56 forks source link

Initializing global PageTransition #75

Closed Samleet closed 10 months ago

Samleet commented 1 year ago

Is it posiible to declare the page transition once and wrap all routes on it rather than having to implement the TransitionType on every route builder?

kalismeras61 commented 10 months ago

This should work please use like it.

theme: ThemeData( primarySwatch: Colors.blue, pageTransitionsTheme: PageTransitionsTheme( builders: { TargetPlatform.iOS: PageTransition(type: PageTransitionType.fade, child: this) .matchingBuilder, }, ), ),