Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
aeronmen2

Image appearing "laggy" with stagger

Recommended Posts

Hello, i've tried to make an image appear with stagger, you can see on the code that it's for the const 11. Everytime i start the site the site load great but as soon as the image appear the site become laggy for 1sec and then proceed to load everything else. 

I'm using Chrome on macOS. Thank you for you help ! 

See the Pen eYeOmLm by aeronmen2 (@aeronmen2) on CodePen

Link to comment
Share on other sites

I don't see any lag whatsoever. But if there is a lag, it has nothing to do with GSAP - it almost surely has to do with browser graphics rendering. 

 

By the way, you could greatly simplify your code - you don't need to use .fromTo() for everything and there's no point to having a "stagger" defined on a tween that only has one target - staggers only apply when there are MULTIPLE targets in a tween. Here's how you could approach it in a simplified way: 

See the Pen RwjbRKw?editors=0010 by GreenSock (@GreenSock) on CodePen

  • Like 2
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.
×