discontinuedPackage logging_manager_flutter has been discontinued.

Logging Manager for Flutter Projects

Pub:logging

Provides simple APIs for logging & managing logs. Logging manager with flutter support.

Features

  • Provides FlutterLoggingManager as a replacement for LoggingManager for flutter projects.
  • FlutterLoggingManager has onFlutterError method which can be capture flutter error.
FlutterError.onError = loggingManager.onFlutterError;

Get Started - Dependency setup

Either add dependency in pubspec.yaml file

    logging_manager_flutter: ^1.0.0

Or add dependency with

    flutter pub add logging_manager_flutter

Usage

  1. Import this package in file.
import 'package:logging_manager_flutter/logging_manager_flutter.dart';
  1. Create a FlutterLoggingManager. Note: A LoggingTree is responsible for doing something with logs. If none provided, nothing will happen.
final loggingManager = FlutterLoggingManager(
   tree: PrintingColoredLogsTree(),
);
  1. Optionally add flutter logging manager to record flutter errors.
FlutterError.onError = loggingManager.onFlutterError;
  1. Get package:logging's logger from above manager.
final appLogger = loggingManager.logger;
  1. Use logger to log anything.
appLogger.info('Hello World');

Additional Information

For more usage see Logging Manager package.