Repository navigation
package.json diagnostics in --module nodenext #46861
Copy link
Copy link
Open
Labels
Domain: ES ModulesThe issue relates to import/export style module behaviorThe issue relates to import/export style module behaviorIn DiscussionNot yet reached consensusNot yet reached consensusRescheduledThis issue was previously scheduled to an earlier milestoneThis issue was previously scheduled to an earlier milestoneSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
Activity
- addedExperience EnhancementNoncontroversial enhancementsNoncontroversial enhancementsSuggestionAn idea for TypeScriptAn idea for TypeScriptand removedSuggestionAn idea for TypeScriptAn idea for TypeScriptExperience EnhancementNoncontroversial enhancementsNoncontroversial enhancements
on Nov 18, 2021 - addedDomain: ES ModulesThe issue relates to import/export style module behaviorThe issue relates to import/export style module behaviorIn DiscussionNot yet reached consensusNot yet reached consensusSuggestionAn idea for TypeScriptAn idea for TypeScript
on Nov 18, 2021 If you want
typesto be the first condition I suggest to update the 4.5 beta blog posts like https://devblogs.microsoft.com/typescript/announcing-typescript-4-5-beta/ which contain the, according to you, wrong order (typesis last in theexportsmap example)andrewbranch commented
on Nov 19, 2021 MemberAuthorMore actionsI think we fixed that for the RC/stable post, Daniel Rosenwasser (@DanielRosenwasser) is it worth going back to that?
DanielRosenwasser commented
on Feb 7, 2022 MemberMore actionsLet's discuss this at an upcoming design meeting.
- addedRescheduledThis issue was previously scheduled to an earlier milestoneThis issue was previously scheduled to an earlier milestone
on May 13, 2022
Metadata
Metadata
Assignees
Labels
Domain: ES ModulesThe issue relates to import/export style module behaviorThe issue relates to import/export style module behaviorIn DiscussionNot yet reached consensusNot yet reached consensusRescheduledThis issue was previously scheduled to an earlier milestoneThis issue was previously scheduled to an earlier milestoneSuggestionAn idea for TypeScriptAn idea for TypeScript
In #46334, it became clear that it’s very easy to mess up writing export maps that will work correctly with
--module nodenext. We would like to explore issuing diagnostics in package.json files in two scenarios (only innode12andnodenext):typescondition is not the first condition in an export mapdefaultcondition is not the last condition in an export mapVS Code currently doesn’t synchronize unsaved changes to package.json files to TS Server (same as tsconfig.json files), so sending errors to the editor can only be done after a manual save. After getting the diagnostics in tsc, we’ll have to evaluate whether the experience in the editor is acceptable, or if we need to start syncing live changes to TS Server.