Use Velocity.js or Transit.js for CSS/JS/jQuery animations?

2.9k views Asked by At

I have been using jQuery's .animate() to animate websites and absolutely love how it works. However I just learned that Velocity.js and Transit.js perform way faster, can animate CSS3 transitions and can be used in jQuery just like .animate().

Should I use Velocity.js or Transit.js for animations? And why?

1

There are 1 answers

0
Ronald On BEST ANSWER

According to the tests on this page, velocity is the best(gives smoothest animations): Speed Test http://codepen.io/GreenSock/pen/pmknI

Using these libraries greatly increased the smoothness of my animations on mobile devices.

However I've done tests on memory consumption (looking at browser's task manager) and I saw that every time I did the animation with velocity or transit, it used up a lot more memory (3MB) every time I kicked off the animation ( not to mention it took the Garbage Collector a long time to reclaim this memory)

On the other hand calling jQuery's animate used an average 1MB to perform the same animation.