winston-bugsnag

Bugsnag transport for Winston

Usage no npm install needed!

<script type="module">
  import winstonBugsnag from 'https://cdn.skypack.dev/winston-bugsnag';
</script>

README

Winston-Bugsnag

Bugsnag transport for Winston

Installation

npm install winston-bugsnag --save

Usage

import * as bugsnag from 'bugsnag'
import { add } from 'winston'
import { BugsnagTransport } from 'winston-bugsnag'

bugsnag.register('Bugsnag api key goes here')
add(BugsnagTransport)

Passing userId to Bugsnag

import * as bugsnag from 'bugsnag'
import { add, log } from 'winston'
import { BugsnagTransport } from './'

bugsnag.register('api key goes here')
add(BugsnagTransport)

log('info', 'something', {
  userId: 'abcdef'
})

License

MIT