Capítulo 163 de 411
A helper that combines two different eases into one — using one ease's shape near the start of the tween and gradually crossfading to a second ease's shape by the end, optionally controlled by a third "blender" ease.
ease."power4.inOut").function blendEases(startEase, endEase, blender) {
var parse = (ease) => (typeof ease === "function" ? ease : gsap.parseEase("power4.inOut")),
s = gsap.parseEase(startEase), e = gsap.parseEase(endEase), blender = parse(blender);
return (v) => {
var b = blender(v);
return s(v) * (1 - b) + e(v) * b;
};
}
gsap.to("#target", { duration: 2, x: 100, ease: blendEases("back.in(1.2)", "bounce") });
back.in overshoot and finishes with a bounce landing, blended smoothly across the tween.