-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Fix extensions for noDtsResolution in node16/nodenext #49233
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@DanielRosenwasser can we put this into the next patch, whenever it goes out? |
Sure! |
@typescript-bot pack this |
Heya @DanielRosenwasser, I've started to run the tarball bundle task on this PR at 1ab6396. You can monitor the build here. |
Heya @DanielRosenwasser, I've started to run the perf test suite on this PR at 1ab6396. You can monitor the build here. Update: The results are in! |
Heya @DanielRosenwasser, I've started to run the extended test suite on this PR at 1ab6396. You can monitor the build here. |
Heya @DanielRosenwasser, I've started to run the parallelized Definitely Typed test suite on this PR at 1ab6396. You can monitor the build here. |
Heya @DanielRosenwasser, I've started to run the diff-based community code test suite on this PR at 1ab6396. You can monitor the build here. Update: The results are in! |
@DanielRosenwasser |
Hey @DanielRosenwasser, I've packed this into an installable tgz. You can install it for testing by referencing it in your
and then running There is also a playground for this build and an npm module you can use via |
@DanielRosenwasser Here they are:Comparison Report - main..49233
System
Hosts
Scenarios
Developer Information: |
@typescript-bot cherry-pick this to release-4.7 |
Heya @andrewbranch, I've started to run the task to cherry-pick this into |
Hey @andrewbranch, I've opened #49244 for you. |
Component commits: 1ab6396 Fix extensions for noDtsResolution in node16/nodenext
let extensions = compilerOptions.noDtsResolution ? [Extensions.TsOnly, Extensions.JavaScript] : tsExtensions; | ||
if (compilerOptions.resolveJsonModule) { | ||
extensions = [...extensions, Extensions.Json]; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let extensions = compilerOptions.noDtsResolution ? [Extensions.TsOnly, Extensions.JavaScript] : tsExtensions; | |
if (compilerOptions.resolveJsonModule) { | |
extensions = [...extensions, Extensions.Json]; | |
} | |
const extensions = compilerOptions.noDtsResolution ? | |
compilerOptions.resolveJsonModule ? [Extensions.TsOnly, Extensions.JavaScript, Extensions.Json] : [Extensions.TsOnly, Extensions.JavaScript] : | |
compilerOptions.resolveJsonModule ? tsPlusJsonExtensions : tsExtensions; |
Component commits: 1ab6396 Fix extensions for noDtsResolution in node16/nodenext Co-authored-by: Andrew Branch <andrew@wheream.io>
Fixes 🙃 #49003 (comment)