Share Posted January 23, 2020 Hi, I'm trying to read a scale value of a transform from an element, but I always get undefined. The selector is simple as that: document.querySelector(".logo")._gsTransform I'm using gsap 3. any idea? Thanks Link to comment Share on other sites More sharing options...
Share Posted January 23, 2020 This is a new feature in GSAP3. No more _gsTransform. Quote What old code will definitely break? Anything that references _gsTransform (use the new gsap.getProperty() method instead) 2 Link to comment Share on other sites More sharing options...
Share Posted January 23, 2020 As benoit said, you should use getProperty() instead of _gsTransform. It's best to not try to access any _ variables in GSAP (and a general good rule of thumb in JS in general). 1 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