Share Posted August 29, 2022 Heya, Have there been any advancements in terms of updating values on resize without calling an onResize function and recreating the timeline? Link to comment Share on other sites More sharing options...
Share Posted August 29, 2022 Hey there, thanks for being part of Club GreenSock! That's hard to say for sure without seeing your specific use case. With ScrollTrigger we have invalidateOnRefresh, but largely for timelines the best method is to recreate on a debounced resize event, yes. Can you maybe pop a pen together for us? Link to comment Share on other sites More sharing options...
Author Share Posted August 29, 2022 do you have a debounce example as you mentioned? Also, is there a way to define a value as a function every time the playhead hits that tween? Or is that function only called once upon creation. Link to comment Share on other sites More sharing options...
Share Posted August 29, 2022 Hey, @martis. Would you please provide a minimal demo (like a CodePen) that clearly shows what you're trying to do in the most basic fashion possible? You might want to look at the new gsap.matchMedia() method. 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