Destination<T extends DestinationParameters>.transit constructor

Destination<T extends DestinationParameters>.transit({
  1. required String path,
  2. required NavigationController? navigator,
  3. Widget builder(
    1. BuildContext context,
    2. T? parameters,
    3. WidgetBuilder childBuilder
    )?,
  4. bool isHome = false,
  5. List<Redirection> redirections = const <Redirection>[],
  6. DestinationSettings? settings,
  7. String? tag,
})

Creates a destination that provides a navigator with nested destinations.

An optional builder parameter is basically the same like normal Destination.builder, but has additional childBuilder parameter, which provides the nested content that built by navigator. The implementation of builder function must include this child widget sub-tree in the result for correct displaying the nested content.

Implementation

Destination.transit({
  required this.path,
  required this.navigator,
  Widget Function(
          BuildContext context, T? parameters, WidgetBuilder childBuilder)?
      builder,
  this.isHome = false,
  this.redirections = const <Redirection>[],
  DestinationSettings? settings,
  this.tag,
})  : builder = null,
      parameters = null,
      parser = const DefaultDestinationParser(),
      settings = settings ?? const DestinationSettings.material(),
      upwardDestinationBuilder = null,
      _transitBuilder = builder;