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

fix(typescript-estree): ensure backwards compat with pre-5.3 import attributes #7967

Merged
merged 1 commit into from
Nov 21, 2023

Conversation

bradzacher
Copy link
Member

PR Checklist

Overview

We don't have old TS version regression tests so this is a bit of a "trust me bro".
Manual test steps:

  1. checkout branch
  2. yarn && yarn build
  3. copy folder packages/typescript-estree/dist
  4. open a new folder
  5. yarn add @typescript-eslint/typescript-estree
  6. run node and use the repl from the issue (require('@typescript-eslint/typescript-estree').parse('import json from "./foo.json" assert { type: "json", type: "bar" };').body[0].attributes) --> observe the broken AST is printed.
  7. paste the copied dist folder to node_modules/@typescript-eslint/typescript-estree/
  8. run node and use the repl from the issue --> observe the correct AST is printed.

screenshot of console showing output of the above steps

@bradzacher bradzacher added the bug Something isn't working label Nov 20, 2023
@typescript-eslint
Copy link
Contributor

Thanks for the PR, @bradzacher!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint.

Copy link

netlify bot commented Nov 20, 2023

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit a7d2b8e
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/655bef87a3423b000850bfe1
😎 Deploy Preview https://deploy-preview-7967--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 98 (🟢 up 7 from production)
Accessibility: 100 (no change from production)
Best Practices: 92 (no change from production)
SEO: 98 (no change from production)
PWA: 80 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

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

Indira Shetty from Gen V saying 'I trust you'

@bradzacher bradzacher merged commit 810fc8c into main Nov 21, 2023
59 checks passed
@bradzacher bradzacher deleted the 7960-import-attribute-backwards-compat branch November 21, 2023 00:09
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: Unexpected node TSAssertEntry
2 participants