Jump to content
Search Community

NS_ERROR_FAILURE with TweenMax, SVG and Firefox

ElliotGeno test
Moderator Tag

Go to solution Solved by ElliotGeno,

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

  • 9 months later...

I am having this same issue now. However the SVG is inlined to the DOM and is not under any circumstance display:none in any of its parents. Its really pissing me off. The weird thing is in this codepen it works fine:

 

See the Pen MarYZr?editors=101 by pr1nt_r (@pr1nt_r) on CodePen

 

But on my site it NS_ERROR_FAILURE. I can't for the life of me figure out what is going on. Is there anything you guys can think of at all that could cause this if not the display:none issue?

 

btw its pretty much impossible to debug GSAP midtween :( I had to go turning every tween off/on to figure out which one it was to even isolate the code that was producing it.

 

Maybe adding some error handling that identified the element selector being tweened?

Link to comment
Share on other sites

Just to put my 2 cents..

 

Firefox has a bug report someone submitted .. but it is really not a bug it is what the SVG spec dictates, that when you try to access an element that is an SVG element that is either missing, has display:none or not visible. It will throw that NS_ERROR_FAILURE, since any element that is missing, has display:none or hidden will be removed from the render tree making it throw that error since it does not exist.

 

https://bugzilla.mozilla.org/show_bug.cgi?id=612118

 

:)

  • Like 2
Link to comment
Share on other sites

  • 2 months later...
  • 5 months later...

Thanks Carl... typical noob mistake... apologies for wasting your time... I would say (barring a few token noob errors like this) I have managed to get up and running with Green Sock within a couple of days with fairly limited JS knowledge so kudos to the team!

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...