- InsomniaNY first isolated the Backbone Events code
- lodash is a dependancy
- I've refactored and cleaned up to satisfy Webpack/React linting in create-react-app
- Converted to node_module format
import Bevent from 'bevent.js';
window.Bevent = Bevent;
Bevent.on('myevent', function(){
// code
});
Bevent.trigger('myevent');
Bevent.on('myevent', function(data){
// code
});
Bevent.trigger('myevent', data);