Desired Behavior
Throw an error if tsconfig.compilerOptions.module is other than "commonjs".
Is this request related to a problem?
I have a command-line application that loads ts-node if it's installed. Users can use typescript for almost everything in that case.
The problem is that some users may accidentally set the tsconfig.compilerOptions.module to incompatible values. If this happens, the errors they get are pretty hard to understand.
Alternatives you've considered
We could validate this ourselves, but that would mean reimplementing how ts-node chooses which tsconfig.json to use.
Additional context
This request should be updated if ts-node were to support the new native ESM mode of node.
Desired Behavior
Throw an error if
tsconfig.compilerOptions.moduleis other than "commonjs".Is this request related to a problem?
I have a command-line application that loads ts-node if it's installed. Users can use typescript for almost everything in that case.
The problem is that some users may accidentally set the
tsconfig.compilerOptions.moduleto incompatible values. If this happens, the errors they get are pretty hard to understand.Alternatives you've considered
We could validate this ourselves, but that would mean reimplementing how
ts-nodechooses whichtsconfig.jsonto use.Additional context
This request should be updated if
ts-nodewere to support the new native ESM mode of node.