Importing from jomini/slim results in type errors or resolves to the any type (it's not clear why there's a different in resolved type).
Updating module and moduleResolution to Node16, and updating imports to include js file extension seems to fix the problem by having jomini create type declaration files that also have imports with file extensions. But this seems highly specific to esm, and I still want to support commonjs and other environments that don't use Node16 module resolution.
Importing from
jomini/slim
results in type errors or resolves to theany
type (it's not clear why there's a different in resolved type).Updating
module
andmoduleResolution
toNode16
, and updating imports to includejs
file extension seems to fix the problem by havingjomini
create type declaration files that also have imports with file extensions. But this seems highly specific to esm, and I still want to support commonjs and other environments that don't useNode16
module resolution.And I tried something like:
But that didn't solve the issue and I don't know why 🤷
The temporary solution is to create a declaration file like
custom.d.ts
with the following in downstream projects: