Skip to content

fix: declare missing dependencies caught in pnpm mode#57474

Open
Saadnajmi wants to merge 3 commits into
react:mainfrom
Saadnajmi:declare-hoisted-direct-deps
Open

fix: declare missing dependencies caught in pnpm mode#57474
Saadnajmi wants to merge 3 commits into
react:mainfrom
Saadnajmi:declare-hoisted-direct-deps

Conversation

@Saadnajmi

Copy link
Copy Markdown
Contributor

Summary:

Upstreaming part of microsoft#3010 (enabling Yarn v4's pnpm mode, which requires stricter dependency declarations). Several first-party packages import modules they don't declare, resolving only via a hoisted node_modules:

  • @react-native/metro-babel-transformer: metro-babel-transformer
  • @react-native/fantom: metro, metro-config, jest-docblock, jest-message-util, source-map
  • @react-native/babel-plugin-codegen: @babel/plugin-syntax-flow (devDependency)

Changelog:

[GENERAL] [FIXED] - declare missing dependencies caught in pnpm mode

Test Plan:

CI should pass

Upstreaming part of microsoft#3010 (enabling Yarn v4's pnpm
mode, which requires stricter dependency declarations). Several first-party
packages import modules they don't declare, resolving only via a hoisted
node_modules:

- @react-native/metro-babel-transformer: metro-babel-transformer
- @react-native/fantom: metro, metro-config, jest-docblock, jest-message-util, source-map
- @react-native/babel-plugin-codegen: @babel/plugin-syntax-flow (devDependency)

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@meta-cla meta-cla 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 Jul 7, 2026
@facebook-github-tools facebook-github-tools Bot added p: Microsoft Partner: Microsoft Partner labels Jul 7, 2026
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@facebook-github-tools facebook-github-tools Bot added the Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team. label Jul 7, 2026
- source-map: ^0.7.4 -> ^0.6.1. Fantom uses the synchronous SourceMapConsumer
  constructor, which is the 0.6.x API; 0.7+ returns a Promise. 0.6.1 is also
  already resolved in the lockfile, avoiding a new major.
- @babel/plugin-syntax-flow: ^7.25.0 -> ^7.26.0 to match the range already
  present in the lockfile.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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. p: Microsoft Partner: Microsoft Partner Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant