logging_appenders 0.4.3+1
logging_appenders: ^0.4.3+1 copied to clipboard

Dart native
Flutter Android iOS

Logging appenders for the dart logging package for print, file and remote (logz, loki).

example/lib/main.dart

import 'package:logging/logging.dart';
import 'package:logging_appenders/logging_appenders.dart';

final _logger = Logger('example');

void main() {
  Logger.root.level = Level.ALL;
  final appender = PrintAppender.setupLogging(stderrLevel: Level.SEVERE);
//  Equal to:
//  final appender = PrintAppender(formatter: const ColorFormatter())
//    ..attachToLogger(Logger.root);
  _logger.fine('Lorem ipsum');
  _logger.info('An important info message');
  _logger.severe('This is bad.');
  _logger.shout('This is just impolite');

  // optionally dispose of the appender.
  appender.dispose();
}
7
likes
100
pub points
85%
popularity

Publisher

codeux.design

Logging appenders for the dart logging package for print, file and remote (logz, loki).

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

clock, dio, intl, io, logging, meta

More

Packages that depend on logging_appenders