Currently, when using the plugin within a TypeScript file, the validating tools complain about missing type declarations. All of the components imported from the plugin (TransitionLink, AniLink, TransitionState and TransitionPortal) are implicitly set as type any.
For example,
import TransitionLink from "gatsby-plugin-transition-link"
results in errors like
Could not find a declaration file for module 'gatsby-plugin-transition-link'. 'node_modules/gatsby-plugin-transition-link/index.js' implicitly has an 'any' type.
Try `npm install @types/gatsby-plugin-transition-link` if it exists or add a new declaration (.d.ts) file containing `declare module 'gatsby-plugin-transition-link';`
That means that things work just fine, but there’s no TypeScript magic ✨ when it comes to using the plugin.
The way to fix this would be to add a declaration file, of course. I think it would make the plugin a lot more usable in TypeScript environments.
Currently, when using the plugin within a TypeScript file, the validating tools complain about missing type declarations. All of the components imported from the plugin (TransitionLink, AniLink, TransitionState and TransitionPortal) are implicitly set as type
any
.For example,
results in errors like
That means that things work just fine, but there’s no TypeScript magic ✨ when it comes to using the plugin.
The way to fix this would be to add a declaration file, of course. I think it would make the plugin a lot more usable in TypeScript environments.