Jump to content
Search Community

Overwrite ScrollMagic issue on one website, but not on CodePen?

Eternalrest test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

In JSFiddle, what I have built works like a charm(timeline with boxes that fade in from left/right). This was copied from a previous website I Have created and it worked perfect there as well. However, for some reason on another website it simply won't work. The error thrown is the overwrite error and I simply can't understand why it won't work considering it's literally the same.


Done with ScrollMagic, GSAP, jQuery.



See the Pen by 88zvhz3c (@88zvhz3c) on CodePen

Link to comment
Share on other sites

Hi and welcome to the GreenSock forums,


I noticed you have some errors about an element with class ".comprehensive" not being found.


Unfortunately, we do not support ScrollMagic (not our product) so you may want to check with their support.

It appears they have done a fantastic job of documenting this issue here: https://github.com/janpaepke/ScrollMagic/wiki/WARNING:-tween-was-overwritten-by-another


It just isn't feasible for us to try to dig through a live site that loads 20+ JavaScript files and do a deep forensic exploration with no way to test the code.


Since overwriting seems to be the root cause, you can debug when an overwrite happens using TweenLite.onOverwrite() and get some info on the tween that was overwritten and the tween that did the overwriting.


The demo below illustrates some of the features of onOverwrite. Perhaps finding the offending tweens will help you find the source of the error.


See the Pen VaGZJz by GreenSock (@GreenSock) on CodePen






  • Like 2
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...