tweene
tweene copied to clipboard
.to() after .set() doesn't work
I'm having the following code:
Tweene.defaultDriver = 'velocity'
Tweene.set($('#header'),{opacity: 0})
Tweene.to($('#header'), {opacity: 1}, {duration: 1000})
I'm trying to set the opacity of this element to 0 instantly and then fading it in. But the opacity seems to be 1 all the time, as if none of the operations are applied. Is this how things are supposed to work?
Hi, thanks for the feedback. It is not supposed to work in that way. I'm currently working on a new release that will solve this kind of issues and add more features too. In the meanwhile, you can easily solve your case with a single instruction:
Tweene.fromTo($('#header'), {opacity: 0}, {opacity: 1, duration: 1000});
Thanks for the fast reply. I'm really looking forward for your next release. Will it include seek support?
Exactly :)