DesignFlowApp constructor

DesignFlowApp({
  1. Key? key,
  2. required String token,
  3. required List<void Function()> dependenciesInitializers,
  4. required RouterConfig<Object> router,
  5. required Map<String, Widget Function()> components,
  6. required Map<String, String Function()> mapComponentsIDToName,
  7. required GlobalKey<NavigatorState> navigatorKey,
  8. ThemeData? theme,
  9. BlocObserver? blocObserver,
  10. bool pathUrlStrategyEnabled = true,
  11. bool loadThemeFromLocalStorage = true,
  12. dynamic onAppStateChanged(
    1. DesignFlowAppState
    )?,
  13. dynamic onDependenciesInitialized(
    1. BuildContext
    )?,
  14. dynamic onCubitsCreated(
    1. BuildContext
    )?,
  15. Translations translations = const EmptyTranslations(),
  16. Locale? initialLocale,
  17. Locale fallbackLocale = const Locale('en', 'US'),
  18. Widget? errorView,
  19. Widget? splashView,
  20. List<BlocProvider<StateStreamableSource<Object?>> Function()> blocProviders = const [],
  21. Iterable<LocalizationsDelegate>? localizationsDelegates,
  22. Iterable<Locale> supportedLocales = const <Locale>[Locale('en', 'US')],
})

Implementation

DesignFlowApp({
  super.key,
  required this.token,
  required this.dependenciesInitializers,
  required this.router,
  required this.components,
  required this.mapComponentsIDToName,
  required this.navigatorKey,
  this.theme,
  this.blocObserver,
  this.pathUrlStrategyEnabled = true,
  this.loadThemeFromLocalStorage = true,
  this.onAppStateChanged,
  this.onDependenciesInitialized,
  this.onCubitsCreated,
  this.translations = const EmptyTranslations(),
  Locale? initialLocale,
  this.fallbackLocale = const Locale('en', 'US'),
  this.errorView,
  this.splashView,
  this.blocProviders = const [],
  this.localizationsDelegates,
  this.supportedLocales = const <Locale>[Locale('en', 'US')],
}) {
  this.initialLocale = initialLocale ?? systemLocales.first;
}