With v5 now being ESM and using the exports field in package.json, we're no longer able to pluck out internal types for use in our own libraries.
Just one example (of many), if we wanted to implement a camelCase(value: string, options?: CamelCaseOptions) function we now need to copy/paste the CamelCaseOptions type from type-fest since it is no longer exposed.
Regarding #676 - I realize these types are lacking docs/tests so should not be included in the top-level export, but developers should be able to opt-in to using them (like we could pre-v5).
Suggestion: add the following to the exports field:
"./source/internal": {
"types": "./source/internal/index.d.ts"
},
"./source/*": {
"types": "./source/*/index.d.ts"
}
With v5 now being ESM and using the
exportsfield inpackage.json, we're no longer able to pluck out internal types for use in our own libraries.Just one example (of many), if we wanted to implement a
camelCase(value: string, options?: CamelCaseOptions)function we now need to copy/paste theCamelCaseOptionstype fromtype-festsince it is no longer exposed.Regarding #676 - I realize these types are lacking docs/tests so should not be included in the top-level export, but developers should be able to opt-in to using them (like we could pre-v5).
Suggestion: add the following to the
exportsfield: