Hammaad-m
Content Type
Profiles
Forums
Store
Blog
Product
Showcase
FAQ
Downloads
Posts posted by Hammaad-m
-
-
I'm unable to use the gsap.utils.selector to animate child components in my local React environment. The same code works in the codepen linked, but no animation is played when I run it locally. There are also no errors in the console.
I've attached my React code, the App component is the exact same but the animation simply doesn't work. index.js
Any help would be much appreciated.
See the Pen VwQWGGB by ERROR_Invalid_Syntax (@ERROR_Invalid_Syntax) on CodePen
React GSAP animation not running locally, but working on codepen.io
in GSAP
Posted
Thank you so much for pointing out the quirk with React.Strictmode!
I think it was either the useLayoutEffect running twice and maybe some wierd syntax I was using, but I got the code working now.