logger_success 1.0.0+1 copy "logger_success: ^1.0.0+1" to clipboard
logger_success: ^1.0.0+1 copied to clipboard

Small, easy to use and extensible logger which prints beautiful logs.

example/main.dart

import 'package:logger_success/logger_success.dart';

var logger = Logger(
  printer: PrettyPrinter(),
);

var loggerNoStack = Logger(
  printer: PrettyPrinter(methodCount: 0),
);

void main() {
  print(
      'Run with either `dart example/main.dart` or `dart --enable-asserts example/main.dart`.');
  demo();
}

void demo() {
  logger.d('Log message with 2 methods');

  loggerNoStack.i('Info message');

  loggerNoStack.w('Just a warning!');

  logger.e('Error! Something bad happened', 'Test Error');

  loggerNoStack.v({'key': 5, 'value': 'something'});

  loggerNoStack.s("This is a success message!");

  logger.s("This is a success message!");

  Logger(printer: SimplePrinter(colors: true)).v('boom');
}
2
likes
150
pub points
14%
popularity

Publisher

unverified uploader

Small, easy to use and extensible logger which prints beautiful logs.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

More

Packages that depend on logger_success