Jump to content
Search Community

Can Multiple Timelines Run in One Window at the Same Time

maiya-22 test
Moderator Tag

Recommended Posts

Hi,

 

I am trying to figure out how to approach a project.

 

 In the project, I am going to have

 

  1.  a TimelineMax() timeline running an animation. This animation will be paused, started, restarted, etc.
  2. A second TimelineMax() timeline. While that first timeline is running, I want to have other timelines that target other elements.  These timelines will be triggered based on various events, so they will also be paused, started, restarted, etc.
  3. I can make it so that the elements targeted in the second timeline are not dependents of elements targeted in the first timeline and vise versa.

 

I was planning to do this with Greensock, but then I read a comment that having multiple timelines running in a browser can cause glitches. Is this true? Is there a work-around?

 

I will add a codesandbox to this post soon. But, since it is a general question, I wanted to see if the direction I am trying to go in is okay.

 

Thank you for any pointers! 🌟

Link to comment
Share on other sites

15 minutes ago, maiya-22 said:

I was planning to do this with Greensock, but then I read a comment that having multiple timelines running in a browser can cause glitches. Is this true? Is there a work-around?

That's quite a perplexing statement given I'm unaware of anything of the sort :) I'd love to see where you got it from. The only issues similar to that relate to people misusing timelines and creating logical issues (in fact we have an article focused on the most common GSAP mistakes). But that's the implementation's fault, not anything wrong with GSAP.

 

We're happy to help if you run into any specific issues. 

 

Oh and by the way, Lite/Max stuff is old. We recommend that you use the GSAP 3 syntax.

  • Like 4
Link to comment
Share on other sites

@ZachSaucier Thank you for that information. It is good to know that you can run multiple timelines in a window at once. The comment I read was in one of the replies to a post in the forum. I can look for it. They said something about running multiple timelines at once can cause the animations to get jerky. So, I was unclear if that was just the nature of Green Sock, and wanted to make sure I was using the right tools.

 

Thank you for all of the information. 🌟  I'll read it.  And if I run into any issues, I'll make a code sandbox.

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...