animationframes
Minimalistic way to create JS animations (~1.5 KB). Use prefix to auto-prefix CSS properties.
Battle-tested in my HTML5 Deck of Cards, source.
install
npm install animationframes
usage
; const translate = elstyletransform = `translate(%, %)`;const from = AnimationFrames; const el = document; const animation = delay: 0 duration: 1000 { elstyledisplay = 'none'; } { elstyledisplay = ''; } { ; } { elstyletransform = ''; }; eltextContent = 'Hello world!'; documentbody;
https://jsfiddle.net/o6vac675/4/
Another example: https://jsfiddle.net/pakastin/fjozqopm/
easings
Available easings: https://github.com/pakastin/animationframes/blob/master/src/ease.js
oldskool