-
Notifications
You must be signed in to change notification settings - Fork 12.5k
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
Add module: es2022
#44656
Add module: es2022
#44656
Conversation
@@ -184,7 +184,7 @@ namespace ts { | |||
file: undefined, | |||
start: 0, | |||
length: 0, | |||
messageText: "Argument for '--module' option must be: 'none', 'commonjs', 'amd', 'system', 'umd', 'es6', 'es2015', 'esnext'.", | |||
messageText: "Argument for '--module' option must be: 'none', 'commonjs', 'amd', 'system', 'umd', 'es6', 'es2015', 'es2020', 'es2022', 'esnext'.", |
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.
Interesting to see this hasn't failed. I don't think this even runs 🤔
Should this function return ModuleKind.ES2020 and ES2022 following the TypeScript/src/compiler/utilities.ts Lines 6035 to 6039 in 5afe42e
|
PR seems kind of outdated. |
I'll rebase once anyone reviews this (or a maintainer requests a rebase). |
This is going to look a weeee bit different after a merge since the module: node changes touch many of the same lines, but initially it looks ok. |
Next to module: node12, this is another thing I'm really looking forward to. Currently there is no real setting for node 16 environment, see also https://github.com/microsoft/TypeScript/wiki/Node-Target-Mapping |
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.
This little looks fine to me - @DanielRosenwasser do we want this in for the beta?
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.
I think this seems reasonable.
What could be the default option for this and the highest version, I guess is none and esnext? |
Closes #44653