cereal_beast Posted July 1, 2022 Share Posted July 1, 2022 Im having an issue with the FOUC, I've set the opacity to 0, and autoAlpha to 1 but the animation plays briefly and then disappears? Any idea why thats happening? See the Pen MWVYNdR by gjjr (@gjjr) on CodePen Link to comment Share on other sites More sharing options...
Solution noviedo Posted July 1, 2022 Solution Share Posted July 1, 2022 Hey @cereal_beast, how's going? You are using a .from() function, so in this way, you will never get the correct autoAlpha because you are set the opacity in 0, probably you will need to use a .to() function to trigger the opacity. I did a quick fork from your pen and fixed it, just check it. I fixed your syntaxis regarding the duration position, and also I split the animation into two tweens, a from() function for all properties and just a to() function to the autoAlpha. With the last parameter in the to() tween ('<') we reach to execute both tweens at the same time. I hope helps you! See the Pen mdxJdad by nazarenooviedo (@nazarenooviedo) on CodePen 2 Link to comment Share on other sites More sharing options...
cereal_beast Posted July 1, 2022 Author Share Posted July 1, 2022 Amazing thank you for explaining your edits also! 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