Typescript types don't work out of the box
enyo opened this issue · comments
Mat Simon commented
After installing and importing the package, I get:
There are types at '.../node_modules/easy-speech/dist/index.d.ts', but this result could not be resolved when respecting package.json "exports". The 'easy-speech' library may need to update its package.json or typings.
I'm not entirely sure, but I think changing the exports
field to this should work:
"exports": {
".": {
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/EasySpeech.js"
}
}
},
Jan Küster commented
Please try easy-speech@2.4.0-rc.0
and let me know if things work as expected
Anna commented
Ran into the same problem. Upgrading the version to 2.4.0-rc.0 fixed it for me.
Jan Küster commented
Mat Simon commented
@jankapunkt yes that worked. Thanks!