Support TypeScript `"moduleResolution": "node16"`
See original GitHub issueDescription
In TypeScript 4.7, along the property "module": "node16"
that enables ESM features in TypeScript, there are new values for the property "moduleResolution"
: "node16"
and "nodenext"
. Both values allows importing from dependencies with package.json exports, imports, and self-referencing. Right now, this property is hard-coded to "node"
.
Proposed solution
The svelte-language-server shouldn’t hard-code that property and instead read it from the tsconfig.json
Alternatives
No response
Additional Information, eg. Screenshots
No response
Issue Analytics
- State:
- Created a year ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Documentation - Module Resolution - TypeScript
There are two possible module resolution strategies: Node and Classic. You can use the moduleResolution option to specify the module resolution strategy.
Read more >Add file extension when '--moduleResolution' is 'node16' or ...
TypeScript 4.7: ECMAScript Module Support: Add file extension when '--moduleResolution' is 'node16' or 'nodenext'. Relates to 1.
Read more >node.js - Force TypeScript to generate export/imports with the ...
Also, moduleResolution should be set to Node16 or NodeNext so ESM ... but TypeScript tooling like auto-imports and path completion will ...
Read more >ESM TypeScript Usage - GraphQL Code Generator
For supporting ESM within your application, you need to set moduleResolution to node16 and the (output) module type to node16 (see ...
Read more >Can we support node16 instead of node12 in module for ...
... 'node12', 'nodenext'.; Argument for '--moduleResolution' option must be: 'n… ... You can track this ticket for Typescript 4.7 support:.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you, not sure how that slipped through. Should be fixed now.
Confirmed on my end.