Hi guys,
I am using ScrollTrigger batch like this:
gsap.set(".column", {opacity: .5, y: 20})
var scroll = ScrollTrigger.batch(".column", {
batchMax: 6,
interval: .3,
onEnter: batch => {
gsap.to(batch, {
opacity: 1,
stagger: .3,
duration: .5,
y: 0,
overwrite: true,
});
},
onLeaveBack: batch => {
gsap.to(batch, {
opacity: 0.5,
duration: .3,
y: 20,
overwrite: true
});
},
start: "center bottom",
end: "center top",
});
scroll.getAll().kill();
And I tried to kill it like in example above, but it doesn't work.
I am trying to be able to overwrite ScrollTrigger instance that I created - say that this code exists in my base.js file, now I am wondering if there is a way of overwriting all of those animations or simply get rid of them in my project.js file?