Skip to content

Instantly share code, notes, and snippets.

@Reinmar
Created April 14, 2011 13:26
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 Reinmar/919470 to your computer and use it in GitHub Desktop.
Save Reinmar/919470 to your computer and use it in GitHub Desktop.
var transform_property = (function (el) {
var properties = [
'transform',
'WebkitTransform',
'MozTransform',
'msTransform',
'OTransform'
];
var p;
while (p = properties.shift()) {
if (typeof el.style[p] !== 'undefined') {
return p;
}
}
return false;
})(new Element('div'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment