talker 3.0.0 copy "talker: ^3.0.0" to clipboard
talker: ^3.0.0 copied to clipboard

Advanced Error Handler, Logger, and App Monitoring with Logs History, Report Sharing, Custom Logs, and etc.

example/talker_example.dart

import 'package:talker/talker.dart';

Future<void> main() async {
  final talker = Talker();

  /// Logs with LogLevel
  talker.warning('The pizza is over 😥');
  talker.debug('Thinking about order new one 🤔');
  talker.error('The restaurant is closed ❌');
  talker.info('Ordering from other restaurant...');
  talker.info('Payment started...');
  talker.good('Payment completed! Waiting for pizza 🍕');

  /// [Exception]'s and [Error]'s handling
  try {
    throw Exception('Something went wrong');
  } catch (e, st) {
    talker.handle(e, st, 'Exception with');
  }

  /// Custom logs
  talker.logTyped(YourCustomLog('Something like your own service message'));
}

class YourCustomLog extends TalkerLog {
  YourCustomLog(String message) : super(message);

  @override
  String get title => 'CUSTOM';

  @override
  AnsiPen get pen => AnsiPen()..xterm(121);
}
574
likes
0
pub points
96%
popularity

Publisher

verified publisherfrezycode.com

Advanced Error Handler, Logger, and App Monitoring with Logs History, Report Sharing, Custom Logs, and etc.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

talker_logger

More

Packages that depend on talker