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

outdated

Advanced error handler and logger package for flutter and dart apps

example/talker_example.dart

import 'package:talker/talker.dart';

Future<void> main() async {
  await Talker.instance.configure();

  try {
    throw Exception('Test service exception');
  } catch (e, st) {
    Talker.instance.handle(e, 'Working with string error', st);
  }

  try {
    throw Exception('Service can`t get test data');
  } on Exception catch (e, st) {
    Talker.instance.handleException(e, 'Working with strings exception', st);
  }

  Talker.instance.log(
    'Big app crashing exception in Some service',
    logLevel: LogLevel.critical,
    additional: {
      "timestamp": 1510417124782,
      "status": 500,
      "error": "Internal Server Error",
      "exception": "com.netflix.hystrix.exception.HystrixRuntimeException",
      "message":
          "ApplicationRepository#save(Application) failed and no fallback available.",
      "path": "/application"
    },
  );

  Talker.instance.fine('Log info');
  Talker.instance.error('Log info');
  Talker.instance.good('Log info');
  Talker.instance.verbose('Log info');
  Talker.instance.warning('Log info');
}
576
likes
0
pub points
96%
popularity

Publisher

verified publisherfrezycode.com

Advanced error handler and logger package for flutter and dart apps

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

intl, talker_error_handler, talker_logger

More

Packages that depend on talker