Jump to content
Search Community

nuxt3 - GSAP animation not running after NuxtLink navigate in same layout

guehring test
Moderator Tag

Recommended Posts

  • guehring changed the title to nuxt3 - GSAP animation not running after NuxtLink navigate in same layout

Hi @guehring and welcome to the GreenSock forums!

 

I think this is related to something in Nuxt or Vue+SSR than GSAP. I forked your example and created a third layout called asdasdasdas.vue and is working as expected:

https://stackblitz.com/edit/github-3g7ck2-ipo3rc?file=pages%2Ftest1.vue

 

For some reason that I couldn't tell you, either Nuxt or Vue+SSR don't treat a component or layout with the text main in it in the same way they treat other files. This is definitely not a GSAP problem since when you use another name for the file it works as expected, so you should use different names for your layouts and ask around Nuxt's discord channel or create an issue on Nuxt's github repo.

 

Finally keep in mind that Nuxt3 is still in release candidate stage, not even beta, so my advice would be to play around with it but don't waste a lot of time since is quite probable that some of the API could change when they release anything close to a stable version.

 

Let us know if you have more questions.

 

Happy Tweening!

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