import transit from 'object-transit';
const object = transit({ a: 0 }, console.log);
object.to(
{ a: 100 },
{
duration: 300
}
);
https://sunify.github.io/object-transit/
-
duration
— duration in ms, defaults to300
-
easing
— simple easing function that takes one argument — time (from 0 to 1). Defaults tolinear
. You can use functions from eases or similar package -
fps
— defaults to60
-
end
— transition end callback