Last active
November 1, 2018 08:07
-
-
Save elijahmanor/6452535 to your computer and use it in GitHub Desktop.
Element matches Polyfill
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
if (Element && !Element.prototype.matches) { | |
var proto = Element.prototype; | |
proto.matches = proto.matchesSelector || | |
proto.mozMatchesSelector || proto.msMatchesSelector || | |
proto.oMatchesSelector || proto.webkitMatchesSelector; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment