Hi @OSUblake and @mango-nyc,
I've been going in circles, I hope you can help. I'm also trying to get the plugins working inside Nuxt.
GSAP3 itself runs just fine as a normal import, however when trying to get the premium plugins working I'm getting stuck.
I've added gsap to Nuxt via Yarn (./gsap-bonus.tgz), and imported gsap and MorphSVG from the folder.
If I try import from the non-dist folder (with build / transpile setting as above in the nuxt config ), I get an error :
_toArray is not a function
If I import from the dist folder (UMD?), as above, I get a window error. I've encountered this before and understand it's because the SSR side doesn't have a window. If I then wrap the imports in the (process.client) check (to force client side), and convert them to requires instead, I still get a window error.
Cannot assign to read only property 'window' of object
I've created a CodeSandbox with the zip inside to demonstrate, I will happily paste the link if that's okay.
It'd be great to get a definitive boilerplate setup for these issues. I feel like I've tried all the advice I've seen, but am still getting stuck.
Thanks for the support.