Skip to content

Instantly share code, notes, and snippets.

@amadeus
Created February 26, 2011 22:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save amadeus/845696 to your computer and use it in GitHub Desktop.
Save amadeus/845696 to your computer and use it in GitHub Desktop.
JS Prefix Tests
var prefix = (function(){
var list = ['', 'webkit', 'Moz', 'O', 'ms'],
element = document.html;
for (var i = 0; i < list.length; i++){
var prefix = list[i];
if (element.style[prefix ? prefix + 'Transform' : 'transform'] != null)
return prefix.toLowerCase();
}
return '';
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment