logtown-sentry-server
v2.4.5
Published
Logtown wrapper for sentry logger on server side
Downloads
3
Maintainers
Readme
logtown-sentry-server
Logtown wrapper for sentry logger on server side
Installation
yarn add logtown-sentry-server raven
or
npm install logtown-sentry-server raven
Usage
const logtown = require('logtown');
const SentryWrapper = require('logtown-sentry-server');
logtown.addWrapper(new SentryWrapper('https://<key>:<secret>@sentry.io/<project>'));
const logger = logtown.getLogger('my-namespace');
logger.warn('Hello Sentry');
logger.error(new Error('Caution there is an error!'));
For reference of sentry options see sentry docs
ES5 usage
var SentryWrapper = require('logtown-sentry-server/es5');
License
Logtown-sentry-server is released under the MIT license.