AppStatefulWidget constructor
AppStatefulWidget({
- Key? key,
- Widget? loadingScreen,
- bool? circularProgressIndicator = true,
- FlutterExceptionHandler? errorHandler,
- ErrorWidgetBuilder? errorScreen,
- ReportErrorHandler? errorReport,
- bool? allowNewHandlers = true,
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.loadingScreen,
this.circularProgressIndicator = true,
// ignore: avoid_unused_constructor_parameters
FlutterExceptionHandler? errorHandler,
// ignore: avoid_unused_constructor_parameters
ErrorWidgetBuilder? errorScreen,
// ignore: avoid_unused_constructor_parameters
v.ReportErrorHandler? errorReport,
bool? allowNewHandlers = true,
}) : _app = v.AppObject(allowNewHandlers: allowNewHandlers),
super(key: key ?? GlobalKey<_StateApp>()) {
// defer displaying anything while starting up
if (circularProgressIndicator == null || !circularProgressIndicator!) {
WidgetsFlutterBinding.ensureInitialized().deferFirstFrame();
}
}