displayError method
Display the Error details in a widget. try..catch to ensure a widget is returned.
Implementation
Widget displayError(FlutterErrorDetails details) {
Widget widget;
try {
widget = ErrorWidget.builder(details);
} catch (ex) {
// low-level primitives used to display the error
widget = errorDisplayWidget(details);
}
return widget;
}