0

Curious CSS transform behavior in chrome (webkit browser) using JavaScript...

var obj = document.getElementById('foooo');
// obj.style.transform == ""; 

obj.style.transform = "rotate(45deg)";  // works (another 2d transform)
obj.style.transform = "translate(-50px,0px)";         // fails as "" (bug?)
obj.style.WebkitTransition = "translate(-50px,0px)";  // fails as ""
obj.style.MozTransition = "translate(-50px,0px)";     // fails as ""
obj.style = "transform: translate(-50px,0px)";  // works (solution)

Any ideas why this happens, or if this error is repeatable?

Jason
  • 1,974
  • 24
  • 19
  • pls link duplicate if it exists, i did a basic search and didn't see anything related – Jason Jul 12 '16 at 05:14
  • the duplicate link should work, but I get the same error: not setting the transform property. I have no idea if it's an obscure problem with my code, so probably not important anyway. – Jason Jul 12 '16 at 05:21

0 Answers0