Repository navigation
Conversation
This was referenced Oct 30, 2026
This was referenced Oct 30, 2026
breaking: Remove remaining core-served endpoints from cli-server-api
react-native-community/cli#2877
Draft
huntie
marked this pull request as ready for review
October 30, 2026 11:47
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Context
Migration of the remaining core dev server endpoints from
@react-native-community/cli-server-apiinto core (community-cli-plugin).Core motivation: These endpoints are critical infra! Most notably the WS
/messageendpoint, 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 thatfb-metro-cliprobably can't accept moving all of these intodev-middlewarejust yet.)This diff
Migrate the
/messageand/eventsWebSockets (used by apps, tools and theranddkeyboard commands) and the/reloadroute to core, and switchstartto them.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.
reloadordevMenubroadcast only when the client connects from this machine with the dev server's origin or none. The CLI relays any broadcast from any client.getpeerswith each client's connection query.loadCommunityMiddleware.Changelog: [Internal]
Test Plan
✅ 51 tests pass. Flow and ESLint clean.
✅ RNTester's Metro with this stack:
curl /reloadanswersOKand a client on/messagereceives thereloadbroadcast;/eventsaccepts a connection.✅ On RNTester on iPhone 18 Pro (iOS 27.0), a
devMenubroadcast on/message(as thedkey sends) opens the Dev Menu.