buildWidget method

  1. @override
Widget buildWidget(
  1. BuildContext context,
  2. Controller controller,
  3. ViewModel viewModel
)
override

Implementation

@override
Widget buildWidget(
  BuildContext context,
  Controller controller,
  ViewModel viewModel,
) {
  // TODO: make more inline with our stuff and add presentationType inherited widget to build dialog bottomsheet or scaffold
  final type = FFPresentationProvider.of(context).type;
  switch (type) {
    case FFPresentationType.route:
      return buildRoute(context, controller, viewModel);
    default:
      throw UnimplementedError('Presentation type $type not implemented yet');
  }
}