4. CSS offers: Transitions and Animations
to add movement to the web.
However, JavaScript is still a big player.
5. Turn to JavaScript for animations if:
1 You need to chain or stagger your animations on more
than a few elements.
2 You are animating SVG graphics.
3 Your project needs to support older browsers where CSS
animation is not available.
6. Anime.js
It is a flexible yet lightweight JavaScript animation library.
It works with CSS, Individual Transforms, SVG, DOM and JS Objects.
8. Duration and Speed of
the Animation
Slow enough to notice the change.
Quick enough not to cause waiting.
Example 01
9. Duration and Speed of
the Animation
Optimal Speed: 200 to 500 ms.
Wearables: 150 to 200 ms.
Mobile: 200 to 300 ms.
Tablets: 400 to 450 ms.
Example 02
10. Duration and Speed of
the Animation
Web: 150 to 200 ms.
Since we are accustomed to an almost instant
opening of web-pages in a browser, we expect to
transit between different states quickly as well.
Example 02