Values to animate between, e.g. ["50px", 60]
Note: You can interpolate with more than 2 values, but it's very confusing, so, it's best to choose 2
Accepts EasingOptions or array frame functions
// An array of keyframes that represent said spring animation and
// Total duration (in milliseconds) required to create a smooth spring animation
[
[50, 55, 60, 70, 80, ...],
3500
]
Generated using TypeDoc
Generates an Array of values using frame functions which in turn create the effect of spring easing. To use this properly make sure to set the easing animation option to "linear". Check out a demo of SpringEasing at https://codepen.io/okikio/pen/MWEdzNg
SpringEasing has 3 properties they are
easing
(all the easings from EasingFunctions are supported on top of frame functions like SpringFrame, SpringFrameOut, etc..),numPoints
(the size of the Array the frame function should create), anddecimal
(the number of decimal places of the values within said Array).easing
spring(1, 100, 10, 0)
numPoints
50
decimal
3
By default, Spring Easing support easings in the form,
All Spring easing's can be configured using theses parameters,
spring-*(mass, stiffness, damping, velocity)
Each parameter comes with these defaults
1
100
10
0
e.g.