hypernym-studio / nuxt-gsap

GSAP module for Nuxt.
MIT License
290 stars 12 forks source link

Typescript Issue $gsap not found #35

Closed king-11 closed 2 years ago

king-11 commented 2 years ago

I have a nuxt 2 application using nuxt-gsap-module when I try to access this.$gsap inside any project, it shows errors for $gsap not found. The same error populates down during build and causes issue even though I have it in buildModules for nuxt.config.ts

ivodolenc commented 2 years ago

Hi and thanks for your interest in this module.

I haven't tested this module in typescript setup so I'm not sure if it works well in that environment. However, you can import gsap manually and use it as recommended by official Nuxt 2 guidelines in typescript projects.

king-11 commented 2 years ago

Like other nuxt modules is it possible that we can export types such that user can add it to tsconfig.json

ivodolenc commented 2 years ago

In the Nuxt 2 + typescript setup you don't need this module.

I suggest you install gsap manually and follow official guides for ts projects.

king-11 commented 2 years ago

Thanks will take a look