Tiba Posted November 29, 2021 Share Posted November 29, 2021 Hi all, i'm new to Gsap and web developing in general. I have a quick question regarding gsap and a single animation. Clicking the "+", the animation starts, but i want to animate it even when i re-click it, like to dissolve it. Don't care about the styling. Thanks in advance. See the Pen MWEWadb by tiba22 (@tiba22) on CodePen Link to comment Share on other sites More sharing options...
Solution OSUblake Posted November 29, 2021 Solution Share Posted November 29, 2021 Welcome to the forums @Tiba You need to create your animations outside of the event handler. See the Pen XWeWpKm by GreenSock (@GreenSock) on CodePen 2 Link to comment Share on other sites More sharing options...
Tiba Posted November 30, 2021 Author Share Posted November 30, 2021 15 hours ago, OSUblake said: Welcome to the forums @Tiba You need to create your animations outside of the event handler. Thank you for your answer and the solution. I surely need to study more 1 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