Created
October 29, 2017 19:34
-
-
Save msbrime/05ba1075bc8b3f9864b5477a6930525f to your computer and use it in GitHub Desktop.
Get all events supported by a particular browser
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
function getBrowserEvents () | |
{ | |
var browserEvents = []; | |
for (var e in document) if (typeof document[e] !== "function" && e !== null && e.substring(0, 2) === "on") browserEvents[browserEvents.length] = e.substring(2); | |
return browserEvents; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment