motion
motion copied to clipboard
[Bug] Could not find a declaration file for module '@vueuse/motion'.
What happened? Could not find a declaration file for module '@vueuse/motion'.
Error message
- 'c:/projects/project-name/node_modules/@vueuse/motion/dist/index.mjs' implicitly has an 'any' type.
- There are types at 'c:/projects/project-name/node_modules/@vueuse/motion/dist/index.d.ts',
- but this result could not be resolved when respecting package.json "exports".
Tips The '@vueuse/motion' library may need to update its package.json or typings.
package manager: yarn
Still present.
Could not find a declaration file for module '@vueuse/motion'. 'node_modules/.pnpm/@[email protected][email protected]/node_modules/@vueuse/motion/dist/index.mjs' implicitly has an 'any' type.
There are types at 'node_modules/@vueuse/motion/dist/index.d.ts', but this result could not be resolved when respecting package.json "exports". The '@vueuse/motion' library may need to update its package.json or typings.
They already fixed this, but didn't create a new tag. The error will persist until a new version tag is created. A workaround is add "type" on exports
inside your node_modules:
"exports": {
".": {
+ "types": "./dist/index.d.ts",
"require": "./dist/index.cjs",
"import": "./dist/index.mjs"
},
"./nuxt": {
+ "types": "./dist/nuxt.d.ts",
"require": "./dist/nuxt.cjs",
"import": "./dist/nuxt.mjs"
}
},
Indeed, a 2.0.1 patch should be made and released. However you should be able to use the master branch in npm using npm install "https://github.com/vueuse/motion.git#main" --save
Is there something blocking a 2.0.1 patch release here? Can we help?