Skip to content

Move /status into community-cli-plugin - #59662

Open
huntie wants to merge 1 commit into
pr59661from
pr59662
Open

huntie wants to merge 1 commit into
pr59661from
pr59662

Conversation

@huntie

@huntie huntie commented Oct 30, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Context

Migration of the remaining core dev server endpoints from @react-native-community/cli-server-api into core (community-cli-plugin).

Core motivation: These endpoints are critical infra! Most notably the WS /message endpoint, which carries reload and Dev Menu commands from the terminal and other tools.

The intent is to later move most of these again into dev-middleware (shared by CLI and Expo). For now, this stack focuses on decoupling CLI as an initial migration. (I note also that fb-metro-cli probably can't accept moving all of these into dev-middleware just yet.)

This diff

Migrate /status (used by apps and start to find a running dev server) to core.

Paired with react-native-community/cli#2877, which removes the CLI's copies.

Net changes

This is a non-breaking change when CLI and react-native are shipped in lockstep.

  • Report the Metro projectRoot in the X-React-Native-Project-Root header, which isDevServerRunning compares, where the CLI reports process.cwd().
  • Send Cache-Control: no-store.
  • Remove the FIXMEs in isDevServerRunning and loadCommunityMiddleware that noted the dependency on the CLI.

Changelog: [Internal]

Test Plan

yarn jest packages/community-cli-plugin/src/dev-server

✅ 31 tests pass. Flow and ESLint clean.

✅ RNTester's Metro with this stack: curl /status answers packager-status:running with RNTester's project root and no-store.

✅ RNTester on iPhone 18 Pro (iOS 27.0) loads its bundle from this Metro.

This branch has not been deployed

No deployments
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: Expo Partner: Expo Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant