eve
eve copied to clipboard
Eve fails for event names including Object.prototype properties
E.g.
> eve.on('thing.constructor.hi', function() {})
TypeError: Cannot read property 'hi' of undefined
This is because your recursive traversal through the events object sees that e[names[i]]
exists, and then tries to read e[names[i]].n
.
We hit this with "watch" in Firefox where there's an Object.prototype.watch()