Skip to content
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

Invalid ES2023 target suggested #57683

Closed
gabritto opened this issue Mar 7, 2024 · 3 comments Β· Fixed by #58140
Closed

Invalid ES2023 target suggested #57683

gabritto opened this issue Mar 7, 2024 · 3 comments Β· Fixed by #58140
Assignees
Labels
Bug A bug in TypeScript Fix Available A PR has been opened for this issue

Comments

@gabritto
Copy link
Member

gabritto commented Mar 7, 2024

πŸ”Ž Search Terms

es2023

πŸ•— Version & Regression Information

  • This is the behavior in every version I tried

⏯ Playground Link

No response

πŸ’» Code

// tsconfig.json
{
    "compilerOptions": {
        "target": |
    }
}

πŸ™ Actual behavior

We get completions for "target" that include "ES2023".
If we accept that, we get the following error:
"error TS6046: Argument for '--target' option must be: 'es5', 'es6', 'es2015', 'es2016', 'es2017', 'es2018', 'es2019', 'es2020', 'es2021', 'es2022', 'esnext'."

πŸ™‚ Expected behavior

No suggestion of "ES2023".

Additional information about the issue

@whzx5byb
Copy link

whzx5byb commented Mar 7, 2024

Duplicate of #56303?

@gabritto gabritto changed the title Missing ES2023 target Invalid ES2023 target suggested Mar 7, 2024
@gabritto
Copy link
Member Author

gabritto commented Mar 7, 2024

@rbuckton suggested we should add ES2023 so that we can include ES2023 as a lib if your target is ES2023, but @RyanCavanaugh said we shouldn't have it as a target, so I just wanted to double check.

If we do want to remove it, we need to remove it here.

@RyanCavanaugh
Copy link
Member

I think I was wrong in that one and we should just have targets for every named spec version; even if in practice a few are identical syntaxwise for some stuff, it's way less confusing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Fix Available A PR has been opened for this issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants