Jump to content
Search Community

The counter number does not work with the new version (3.11.1)

Umberto test
Moderator Tag

Go to solution Solved by GreenSock,

Recommended Posts

thanks for the demos. it clearly looks like there is a problem in the latest version.

I reduced it even further just to show that it seems that the issue is closely related to the textContent value on a from() tween.

hopefully this helps the @GreenSock team troubleshoot and offer a solution for you.

the pen below is using one of the latest-beta versions I found in another thread

thanks for your patience

See the Pen poVeOOg by snorkltv (@snorkltv) on CodePen

  • Like 2
Link to comment
Share on other sites

  • Solution

Sorry about the confusion there. It was indeed a regression related to the new revert() functionality (which empowers matchMedia() and context()) that affects when you from() tween non-CSS properties of DOM elements but it should be resolved in the next release which you can preview at https://assets.codepen.io/16327/gsap-latest-beta.min.js

 

Better? 

  • Like 3
Link to comment
Share on other sites

On 9/17/2022 at 8:21 PM, GreenSock said:

Sorry about the confusion there. It was indeed a regression related to the new revert() functionality (which empowers matchMedia() and context()) that affects when you from() tween non-CSS properties of DOM elements but it should be resolved in the next release which you can preview at https://assets.codepen.io/16327/gsap-latest-beta.min.js

 

Better? 

 

Hi, I am trying to install the beta due to this same problem, but I can't find the package in yarn. How can I use it?

 

Thank you in advance

Link to comment
Share on other sites

if (typeof window !== "undefined") {
  gsap.register.plugin(ScrollTrigger);
}

Hi @avizmarques,

 

The team is trying to have everything ready ASAP, as mentioned here:

In the mean time you can add the beta version as a regular script tag. I assume that this is related to a NextJS project you've been working on, so you can use Next's Head component to add the file there. You won't have to import it though, just register the plugin since it will be in the global scope. Be careful to check if the window object exists in order to prevent errors during SSR:

if (typeof window !== "undefined") {
  gsap.registerPlugin(ScrollTrigger);
}

We'll keep you posted.

 

Happy Tweening!!!

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