Jump to content
Search Community

Manually fire ScrollTrigger

NickNo test
Moderator Tag

Recommended Posts

Hi, I've got  a page with a bunch of objects that fade in on scroll - then a bunch of galleries.  What I want to happen is to click a 'load more' and then next set of gallery items animate in. The way I've (quickly) set it up doesn't work - I'm just wondering if I'm on the right track, or do I not even use scrolltrigger, and use something else to do this?

See the Pen GRNwvaN by nickjacobsnz (@nickjacobsnz) on CodePen

Link to comment
Share on other sites

Hey Nick. ScrollTrigger works well in cases like this if you set it up in a way that works. I'd guess that the best way to do it is to select all of the new elements after they've been added and do a new ScrollTrigger.batch() for just those images.

 

Check out this thread:

 

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...