It's easy when use the wow.js library
But I need to do it on GSAP.
const collageItems = document.querySelectorAll(".collage__item");
gsap.from(collageItems, {
scrollTrigger: {
trigger: collageItems,
},
autoAlpha: 0,
y: 150,
duration: 1.5,
ease: "power1.out"
});
When I write the code above, the trigger for all elements is the very first element with the .collage__item class, i.e. all elements with that class start popping up as soon as the first one appears in the window area.
How can I make the popup effect be applied to each item specifically?