Package Exports
- tween-functions
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tween-functions) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Tween-functions
Robert Penner's tweening functions as used in React-tween-state and React-state-stream.
Penner's original functions uses the change in value rather than final value as parameter. I much prefer the latter, so this is what this library will use.
API
tweenFunction.tweenName(currentTime, beginValue, endValue, totalDuration)
Example
var tweenFunctions = require('tween-functions');
tweenFunctions.easeInQuad(1, 0, 50, 5); // => 4
List of available functions:
- linear
- easeInQuad
- easeOutQuad
- easeInOutQuad
- easeInCubic
- easeOutCubic
- easeInOutCubic
- easeInQuart
- easeOutQuart
- easeInOutQuart
- easeInQuint
- easeOutQuint
- easeInOutQuint
- easeInSine
- easeOutSine
- easeInOutSine
- easeInExpo
- easeOutExpo
- easeInOutExpo
- easeInCirc
- easeOutCirc
- easeInOutCirc
- easeInElastic
- easeOutElastic
- easeInOutElastic
- easeInBack
- easeOutBack
- easeInOutBack
- easeInBounce
- easeOutBounce
- easeInOutBounce