π Search Terms
moduleResolution bundler esm imports
β
Viability Checklist
β Suggestion
Add an option to enforce imports with file extension when the module is iESM (type: module) and moduleResolution is bundler.
π Motivating Example
For now in bundler moduleResolution, typescript is tolerent.
But when we develop a library, we have no idea of the strictness of the bundler (webpack is strict for example).
We need a way to enforce the imports with file extension in case the module is ESM
A dedicated option in the tsconfig can resolve it that we will enable or not
π» Use Cases
- What do you want to use this for?
- What shortcomings exist with current approaches?
- What workarounds are you using in the meantime?
π Search Terms
moduleResolution bundler esm imports
β Viability Checklist
β Suggestion
Add an option to enforce imports with file extension when the module is iESM (type: module) and moduleResolution is bundler.
π Motivating Example
For now in bundler moduleResolution, typescript is tolerent.
But when we develop a library, we have no idea of the strictness of the bundler (webpack is strict for example).
We need a way to enforce the imports with file extension in case the module is ESM
A dedicated option in the tsconfig can resolve it that we will enable or not
π» Use Cases