react-sentry
v1.0.2
Published
react-sentry
Downloads
33
Readme
react-sentry
Listen to EventEmitters
safely with automatic cleanup onComponentWillUnmount
.
Example
var Sentry = require('react-sentry')
// ...
mixins: [Sentry],
// ...
getInitialState () {
return { online: this.context.myStore.isOnline() }
},
componentDidMount () {
this.watch(this.context.myStore, 'online', (online) => {
this.setState({ online })
})
},
// ...
License
This library is free and open-source software released under the MIT license.