Jump to content
Search Community

Can't find variable: ResizeObserver

7dots test
Moderator Tag

Go to solution Solved by GreenSock,

Recommended Posts

Hi there,


I was wondering if GSAP's matchMedia uses the ResizeObserver?


We are getting an error on some older versions of Safari and have seen ReferenceError: Can't find variable: ResizeObserver in the console.


Please could you confirm as I'm not sure what else it could be.




Link to comment
Share on other sites

  • Solution

No, @7dots, gsap.matchMedia() doesn't use ResizeObserver at all. ScrollSmoother does, but only if it's supported in that particular browser. So you definitely shouldn't be seeing any errors like that from any GSAP-related stuff. I bet you're referencing ResizeObserver somewhere in your code(?) It's tough to troubleshoot blind, though - if you still need some help just post a minimal demo and we'd be happy to take a peek at anything GSAP-specific. 

Link to comment
Share on other sites

Hey @GreenSock, thanks for clarifying!


It's was erroring in an older version of IOS Safari so I was just working through the node modules I have installed and checking what might be the cause.


I'll be good for help thank you. I've been debugging so hopefully will find something, but nice to know it's not coming from GSAP 👍


Thanks again.



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