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

Update @typescript-eslint/typescript-estree to support satisfies #13872

Merged
merged 8 commits into from Nov 22, 2022

Conversation

sosukesuzuki
Copy link
Member

@sosukesuzuki sosukesuzuki commented Nov 20, 2022

Description

It is still alpha (ref: typescript-eslint/typescript-eslint#5688 (comment)).

Checklist

  • I’ve added tests to confirm my change works.
  • (If the change is user-facing) I’ve added my changes to changelog_unreleased/*/XXXX.md file following changelog_unreleased/TEMPLATE.md.
  • I’ve read the contributing guidelines.

Try the playground for this PR

yarn.lock Outdated Show resolved Hide resolved
@sosukesuzuki
Copy link
Member Author

I think we should release 2.8 after this PR is merged without waiting typescript-estree supports auto accessors because most users want to update to TypeScript 4.9 for the satisfies operators.

@@ -1,10 +1,8 @@
#### Support TypeScript 4.9 (#13764, #13783 by @sosukesuzuki)
#### Support TypeScript 4.9 (#13764, #13783, #13872 by @sosukesuzuki)
Copy link
Member

@kachkaev kachkaev Nov 21, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about this header instead?

Suggested change
#### Support TypeScript 4.9 (#13764, #13783, #13872 by @sosukesuzuki)
#### Support TypeScript 4.9 `satisfies` operator (#13764, #13783, #13872 by @sosukesuzuki)
Suggested change
#### Support TypeScript 4.9 (#13764, #13783, #13872 by @sosukesuzuki)
#### Support TypeScript 4.9 [`satisfies`](https://devblogs.microsoft.com/typescript/announcing-typescript-4-9/#satisfies) operator (#13764, #13783, #13872 by @sosukesuzuki)

Otherwise we start with an overpromise. Instead of adding a header for Auto-Accessors in Classes we can say something like:

[Auto-Accessors in Classes](https://devblogs.microsoft.com/typescript/announcing-typescript-4-9/#auto-accessors-in-classes) will be supported in an upcoming 2.8 patch release. We have de-scoped them for now to ship `satisfies` operator sooner.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't it already supported by babel-ts parser? User can switch to use it temporarily.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@babel/parser can parse auto accessors. But it cannot be used with type annotations to we need to wait babel/babel#15209

fisker
fisker approved these changes Nov 22, 2022
@sosukesuzuki sosukesuzuki merged commit fd37600 into prettier:main Nov 22, 2022
32 checks passed
@sosukesuzuki sosukesuzuki deleted the ts-estree-4.9 branch Nov 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants