ConsoleLogStrategy constructor
ConsoleLogStrategy({})
Constructs a ConsoleLogStrategy.
logLevel
sets the log level at which this strategy becomes active.
supportedEvents
optionally specifies which types of LogEvent this strategy should handle.
useModernFormatting
enables modern console formatting with colors and emojis.
useColors
enables colored output.
showTimestamp
shows timestamp in logs.
showContext
shows context information in logs.
Implementation
ConsoleLogStrategy({
super.logLevel = LogLevel.none,
super.supportedEvents,
bool useModernFormatting = true,
bool useColors = true,
bool showTimestamp = true,
bool showContext = true,
}) : _useModernFormatting = useModernFormatting,
_useColors = useColors,
_showTimestamp = showTimestamp,
_showContext = showContext;