pushWithTransition<T> method
Navigate with animation control
Implementation
Future<T?> pushWithTransition<T>(
RoutePaths route, {
Map<String, String>? params,
Map<String, String>? queries,
Object? extra,
Duration? transitionDuration,
}) async {
try {
final path = (params != null || queries != null)
? route.pathWithParams(params ?? {}, queries: queries)
: route.path;
return await push<T>(path, extra: extra);
} catch (e) {
if (kDebugMode) {
debugPrint('Transition navigation error: $e');
}
return await push<T>(route.path, extra: extra);
}
}