Last active
October 27, 2020 12:31
-
-
Save revenkroz/197501ad93ec96003b02a23aff3d4199 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var oldAddEventListener = EventTarget.prototype.addEventListener; | |
EventTarget.prototype.addEventListener = function(eventName, eventHandler) | |
{ | |
oldAddEventListener.call(this, eventName, function(event) { | |
console.log(eventName); | |
eventHandler(event); | |
}); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment