Created
August 6, 2014 13:26
-
-
Save matijs/49587c7c8c6df58a47a0 to your computer and use it in GitHub Desktop.
feature detect css transforms
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 hasTransforms = (function() { | |
var propNames = ["transform", "MozTransform", "webkitTransform", "msTransform"]; | |
var i = 0; | |
var length = propNames.length; | |
for (; i < length; i++) { | |
if (typeof document.documentElement.style[propNames[i]] === "string") return true; | |
} | |
return false; | |
}()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment