configure static method
void
configure({
- LogLevel? minLevel,
- LogSink? sink,
- VoidCallback captureCrashes = Log.captureCrashes,
Configures the global logger.
By default, invokes captureCrashes so uncaught Flutter / async /
isolate errors flow through e. Pass a different hook (or () {} for
no-op) to customise: test environments or apps that own
FlutterError.onError should pass a no-op.
Implementation
static void configure({
LogLevel? minLevel,
LogSink? sink,
VoidCallback captureCrashes = Log.captureCrashes,
}) {
if (minLevel != null) _minLevel = minLevel;
if (sink != null) _sink = sink;
captureCrashes();
}