AppStatefulWidget constructor

AppStatefulWidget({
  1. Key? key,
  2. Widget? splashScreen,
  3. Widget inSplashScreen()?,
  4. bool? circularProgressIndicator,
})

The entrypoint of the framework passed to runApp() This is a StatelessWidget where you can define the loading screen or the App's error handling.

Implementation

AppStatefulWidget({
  Key? key,
  this.splashScreen,
  this.inSplashScreen,
  this.circularProgressIndicator,
})  : _app = v.AppObject(),
      super(key: key ?? GlobalKey<_AppStatefulWidgetState>()) {
  // Right at the start! Initialise the binding.
  final widgetsBinding = WidgetsFlutterBinding.ensureInitialized();
  final indicator = circularProgressIndicator ?? true;
  if (!indicator) {
    // defer displaying anything while starting up
    widgetsBinding.deferFirstFrame();
  }
}