Share Posted April 15 I've tested on Vivaldi (Chrome), Safari, Firefox, and Edge, all on MacOS, and only on Safari is the tweening of the SVG's position choppy. Any ideas on how to do things more efficiently? It was originally choppy and laggy on all platforms until I added the TweenMax.killTweensOf(this); line. Edit for posterity: the codepen below has been updated with some of the suggestions, so if you come upon this later and don't see what I'm talking about, that's why. See the Pen GRXVedq by ThinkByDesignInc (@ThinkByDesignInc) on CodePen Link to comment Share on other sites More sharing options...
Share Posted April 15 Hi, I can't test on a mac machine, but you could try using quickTo(): https://greensock.com/docs/v3/GSAP/gsap.quickTo() Also you could add will-change: transform to the clip path element you're animating. Hopefully this helps. Happy Tweening! Link to comment Share on other sites More sharing options...
Share Posted April 15 Yep, sorta like this: See the Pen oNaxdje?editors=1010 by GreenSock (@GreenSock) on CodePen Better? And the reason the killTweensOf() helped is because you were creating a TON of conflicting tweens all trying to control the same properties of the same element. You could have solved it equally well by setting overwrite: true. None of that is necessary if you use the gsap.quickTo() technique. Link to comment Share on other sites More sharing options...
Author Share Posted April 16 Awesome! That looks exactly like what I'm looking for, but didn't know existed. I'll try it out and let you know. 1 Link to comment Share on other sites More sharing options...
Author Share Posted April 16 I'll also have to read up on the overwrite: true. I hadn't come across that in my Googling, either. Link to comment Share on other sites More sharing options...
Author Share Posted April 16 Those changes (quickto) have helped a lot. I'll have to check in with the designers to see if it's smooth "enough", though honestly with this and adding will-change (which I'd forgotten about - only used it once before), I'm uncertain if there is more that can be done. I guess I'll find out! Lol. 2 Link to comment Share on other sites More sharing options...
Share Posted April 16 Excellent. Glad to hear it's working well for you. Good luck with the designers. 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