greensock / GSAP

GSAP (GreenSock Animation Platform), a JavaScript animation library for the modern web
https://gsap.com
19.83k stars 1.72k forks source link

jQuery object targets #9

Closed shovemedia closed 11 years ago

shovemedia commented 11 years ago

Shouldn't the following work? I have to use a placeholder object + onUpdate

var $box = $('.box') $box.css('width', '50px'); TweenLite.to($box, 1, {'width': '200px'});

also tried TweenLite.to($box.get(0), 1, {'width': '200px'}); and omitting the px etc

jackdoyle commented 11 years ago

Yes, that code works great. I just tested it. I wonder if maybe you forgot to load TweenLite or CSSPlugin? If you still need some help, could you maybe provide a simple codepen or jsfiddle?

shovemedia commented 11 years ago

Confirmed. I'd omitted CSSPlugin, and my adjustments to support AMD hid it from me. Thanks!