Skip to content

[0.74] Update eslint-plugin-jest to 27.x, @typescript-eslint deps to 7.x - #44764

Merged
huntie merged 1 commit into
react:0.74-stablefrom
huntie:0.74-deps-fix
Jun 4, 2024
Merged

[0.74] Update eslint-plugin-jest to 27.x, @typescript-eslint deps to 7.x#44764
huntie merged 1 commit into
react:0.74-stablefrom
huntie:0.74-deps-fix

Conversation

@huntie

@huntiehuntie commented Jun 3, 2024

Copy link
Copy Markdown
Collaborator

Summary

Picks #43406 into 0.74, resolvesreactwg/react-native-releases#239.

This PR updates @typescript-eslint/eslint-plugin and @typescript-eslint/parser to v7 and eslint-plugin-jest to v27, removing any dependencies on typescript-eslintv6, allowing projects using @react-native/eslint-config to safely update to typescript-eslintv7 without having to worry about duplicate major versions installed

Changelog:

  • [General][Changed]: Update eslint-plugin-jest to 27.x

Test Plan

Sanity checking breaking changes in source packages

✅ The following updates do not clash with minimum tool versions in 0.74 ⬇️. I'm confident we can safely update these dependencies.

Fixed INCOMPATIBLE_PEER_DEPENDENCY

# 1 - Init new 0.74.1 project
npx react-native@latest init RN074
cd RN074/
# 2 - Use `yarn link` (v3) to override @react-native/eslint-config to this PR
yarn link ~/Development/forks/react-native/packages/eslint-config-react-native/
# 3 - Install dependencies
rm -rf node_modules
yarn
BeforeAfter
imageimage

INCOMPATIBLE_PEER_DEPENDENCY warning (quoted below) is not present after changes.

➤ YN0060: │ @react-native/eslint-config@npm:0.74.83 [5fdc1] provides @typescript-eslint/eslint-plugin (pb3bde) with version 6.21.0, which doesn't satisfy what eslint-plugin-jest requests

Lint behaviour

cd RN074/
yarn lint

✅ Succeeds

… to v27 (#43406)
Summary:
This PR updates `typescript-eslint/eslint-plugin` and `typescript-eslint/parser` to `v7` and `eslint-plugin-jest` to `v27`, removing any dependencies on `typescript-eslint` `v6`, allowing projects using `react-native/eslint-config` to safely update to `typescript-eslint` `v7` without having to worry about duplicate major versions installed
## Changelog:
- [General] [Changed]: Updated `eslint-plugin-jest` to `v27`
- [General] [Changed]: Updated `typescript-eslint` monorepo to `v7`
Pull Request resolved: #43406
Test Plan: `yarn run lint` executed locally successfully
Reviewed By: robhogan
Differential Revision: D54749676
Pulled By: tdn120
fbshipit-source-id: f6fae92fc95333e28b36a3d2bd8470c8869d38bc
# Conflicts:
#	package.json
#	packages/eslint-config-react-native/package.json
#	yarn.lock
@facebook-github-botfacebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner labels Jun 3, 2024
@github-actions

Copy link
Copy Markdown
Warnings
⚠️🔒 package.json - Changes were made to package.json. This will require a manual import by a Facebook employee.

Generated by 🚫 dangerJS against e396ece

@huntiehuntie self-assigned this Jun 3, 2024
@analysis-bot

Copy link
Copy Markdown
PlatformEngineArchSize (bytes)Diff
androidhermesarm64-v8a17,837,025-1,739,586
androidhermesarmeabi-v7an/a--
androidhermesx86n/a--
androidhermesx86_64n/a--
androidjscarm64-v8a21,195,194-1,750,952
androidjscarmeabi-v7an/a--
androidjscx86n/a--
androidjscx86_64n/a--

Base commit: 84ff977
Branch: main

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA SignedThis label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.p: FacebookPartner: FacebookPartnerPick Request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@huntie@analysis-bot@cipolleschi@facebook-github-bot@lluiscab