easing-animation
v1.1.1 ( last update: 24 june 2017 )
Animation builder.
Install
npm
npm i easing-animation --save
Node.js
var Animation = ;
Browser
<script src="/node_modules/easing-animation/dist/easing-animation.js"></script>
How to use
Start new one
var animation = Animation;animationstart from: 5 to: 7 duration: 100 easing: Animationeasingeaseout { //on going console; } { //When it's done console; };
Stop when necessary
animation;
On going?
if animationisAnimated // ...
Included easing:
- linear
- easein
- easeout
- easeinout
You are always able to use your own. Example:
// Like this => { return v;} // Or something else => { return v * v;} Animation;
Extra
smoothize(from, to, ease)
Animation;
recolorize(color1, color2, ease)
Animation;
hexToRgb(hex)
var rgb = Animation;var red = Animation;
rgbToHex(r, g, b)
var hex = Animation;var red = Animation;
randcolor()
var color = Animation;