You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When importing anything from allotment, my tsc gives me the following error:
Could not find a declaration file for module 'allotment'. '<(Project path omitted)>/node_modules/allotment/dist/modern.mjs' implicitly has an 'any' type.
There are types at '<(Project path omitted)>/node_modules/allotment/dist/types/src/index.d.ts', but this result could not be resolved when respecting package.json "exports". The 'allotment' library may need to update its package.json or typings.ts(7016)
Hi!
Issue description
When importing anything from
allotment
, mytsc
gives me the following error:Possible context
This seems to be related to the issue reported in TS: microsoft/TypeScript#52363
Environment
allotment 1.19.0
typescript 5.1.6
vite 4.4.4
NodeJS 18.13.0 (Mac M1)
I'm using
"module": "esnext", "moduleResolution": "bundler",
in my tsconfig. No other library so far has given the same error for me.Possible workaround
While it is a hack, the workaround that worked for me so far was to create a typings file like the following:
The text was updated successfully, but these errors were encountered: