Skip to content

Commit ec9fad7

Browse files
authored
Export types as well
Fix: ``` Could not find a declaration file for module 'add-to-calendar-button-react'. 'node_modules/add-to-calendar-button-react/dist/atcb.js' implicitly has an 'any' type. There are types at 'node_modules/add-to-calendar-button-react/dist/index.d.ts', but this result could not be resolved when respecting package.json "exports". The 'add-to-calendar-button-react' library may need to update its package.json or typings. import { AddToCalendarButton } from "add-to-calendar-button-react" ``` I checked the related issues from this main issue and the common way to fix it, is by exporting the types as well: microsoft/TypeScript#52363
1 parent e366513 commit ec9fad7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"types": "./dist/index.d.ts",
1717
"exports": {
1818
".": {
19+
"types": "./dist/index.d.ts",
1920
"import": "./dist/atcb.js",
2021
"require": "./dist/atcb.umd.cjs"
2122
}

0 commit comments

Comments
 (0)