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

Revert to @babel/eslint-parser in eslint-config #47333

Closed
wants to merge 1 commit into from

Conversation

huntie
Copy link
Member

@huntie huntie commented Oct 31, 2024

Summary:
Motivated by facebook/hermes#1549. This was originally changed in #46696, as our internal Flow support had diverged from babel/eslint-parser (#46601).

We effectively have three flavours of JavaScript in support:

  • Flow@latest for the react-native package, shipped as source — uses hermes-parser.
  • TypeScript for product code (community template, Expo) — uses babel/plugin-syntax-typescript.
  • Plain JavaScript or Flow in product code, which may be extended with additional user Babel plugins and needs lenient parsing — uses babel/plugin-syntax-flow via babel/eslint-parser (this change).

I'd love to simplify this 😅.

Switching to hermes-eslint for the RN monorepo codebase (D63541483) is unchanged.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D65272156

Summary:
Motivated by facebook/hermes#1549. This was originally changed in facebook#46696, as our internal Flow support had diverged from `babel/eslint-parser` (facebook#46601).

We effectively have three flavours of JavaScript in support:
- Flow@latest for the `react-native` package, shipped as source — uses `hermes-parser`.
- TypeScript for product code (community template, Expo) — uses `babel/plugin-syntax-typescript`.
- Plain JavaScript or Flow in product code, *which may be extended with additional user Babel plugins and needs lenient parsing* — uses `babel/plugin-syntax-flow` via `babel/eslint-parser` (**this change**).

I'd love to simplify this 😅.

Switching to `hermes-eslint` for the RN monorepo codebase (D63541483) is unchanged.

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D65272156
@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Oct 31, 2024
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D65272156

@facebook-github-bot
Copy link
Contributor

This pull request has been merged in 4afc47a.

@react-native-bot
Copy link
Collaborator

This pull request was successfully merged by @huntie in 4afc47a

When will my fix make it into a release? | How to file a pick request?

@huntie huntie deleted the export-D65272156 branch November 18, 2024 12:26
blakef pushed a commit that referenced this pull request Dec 4, 2024
Summary:
Pull Request resolved: #47333

Motivated by facebook/hermes#1549. This was originally changed in #46696, as our internal Flow support had diverged from `babel/eslint-parser` (#46601).

We effectively have three flavours of JavaScript in support:
- Flow@latest for the `react-native` package, shipped as source — uses `hermes-parser`.
- TypeScript for product code (community template, Expo) — uses `babel/plugin-syntax-typescript`.
- Plain JavaScript or Flow in product code, *which may be extended with additional user Babel plugins and needs lenient parsing* — uses `babel/plugin-syntax-flow` via `babel/eslint-parser` (**this change**).

I'd love to simplify this 😅.

Switching to `hermes-eslint` for the RN monorepo codebase (D63541483) is unchanged.

Changelog: [Internal]

Reviewed By: robhogan, cipolleschi

Differential Revision: D65272156

fbshipit-source-id: 3a2bbe3fcf8ed6057f6d994a0be4985e6bf46fa9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants