addDefaultErrorWidget static method
void
addDefaultErrorWidget({})
Add default error widget which replaces red screen of death (RSOD).
Implementation
static void addDefaultErrorWidget({
bool showStacktrace = true,
String title = "An application error has occurred",
String description =
"There was unexpected situation in application. Application has been "
"able to recover from error state.",
double maxWidthForSmallMode = 150,
}) {
ErrorWidget.builder = (FlutterErrorDetails details) {
return CatcherErrorWidget(
details: details,
showStacktrace: showStacktrace,
title: title,
description: description,
maxWidthForSmallMode: maxWidthForSmallMode,
);
};
}