experimentalExtensionlessBinWorkaround
option to resolve extensionless entrypoints to CJS in ESM loader
#1611
Labels
you can do this
Good candidate for a pull request.
This is labelled to indicate we will accept a pull request that implements this feature.
Intentionally marked experimental so that ts-node can remove or change it at any time without following semver. Intentionally has verbose name to include the word "workaround."
When a user enables this and they use the ESM loader, it will resolve extensionless entrypoints to CJS format to workaround the errors caused by nodejs/node#33226
This is an intentional divergence from node's behavior. Users who enable this flag must understand that it may cause breakages in the future. However, in the present, it will unblock those users, allowing them to combine ts-node/esm with third-party tools that have extensionless bin entrypoints.
Can be named either
experimentalExtensionlessBinWorkaround
orexperimentalExtensionlessEntrypointWorkaround
See also: discussion starting here
#1007 (comment)
The text was updated successfully, but these errors were encountered: