Hey Mikel,
Thanks for this awesome example, this is exactly what i was looking for!
So if I understand correctly, I have to use the Gsap scrolltrigger cdn and register it. Then I have to apply it like in my example below?
var tween = gsap.to("#rec", {
duration: 5,
paused: true,
ease: "none",
motionPath: {
path: "#path",
align: "#path",
autoRotate: true,
alignOrigin: [0.5, 0.5]
},
scrollTrigger: {
trigger: "#path",
scrub:2
}
}).pause(0.001);
Greetz,
Gentian