felek Posted July 14, 2020 Share Posted July 14, 2020 Hello based on this example I want to check when scroll reach end, and then load more data as append from feth method and show them (divs). Is there any example on that ? I check doc and I don`t see any callback onScroll end or some think like that. See the Pen OJMoLKz?editors=1010 by felek (@felek) on CodePen Link to comment Share on other sites More sharing options...
ZachSaucier Posted July 14, 2020 Share Posted July 14, 2020 Hey felek. It'd be best to create a new ScrollTrigger for the point at which you want to load new content. Here's a community-made demo on the subject (it, along with lots of demos of helpful effects, are listed in the ScrollTrigger docs): See the Pen 514f4d19e03ced84b60dfdacc382adce by kdbkapsere (@kdbkapsere) on CodePen 1 Link to comment Share on other sites More sharing options...
felek Posted July 15, 2020 Author Share Posted July 15, 2020 Hey thx. It seems working out. May by it will be use to create callback when scroll is at bottom of / top. Than onUpdate will no have to trigger every time. Link to comment Share on other sites More sharing options...
ZachSaucier Posted July 15, 2020 Share Posted July 15, 2020 6 hours ago, felek said: May by it will be use to create callback when scroll is at bottom of / top Sure, that would be more performant. But you'd need to create a new ScrollTrigger every time the new content is done loading. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now