Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53510
Changelog: [Internal]
Electron imposes a [strange undocumented limitation](https://github.com/electron/electron/pull/13039) on the format of command-line arguments, which for some reason only affects Windows. Basically, the command line is truncated after the first argument that looks like a URL.
Electron's recommendation for avoiding this is to prefix the argument list with `--`, but I prefer switching to a different arg format (`--x=y` instead of `--x y`) that will prevent us from ever running into this issue.
NOTE: I will follow up with a diff to harden arg parsing in our Electron code so that it only accepts the `--x=y` format.
Reviewed By: huntie
Differential Revision: D81237713
fbshipit-source-id: a255dc63b6486b96d9f7ccf780d1b09bc4ddf7e0
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53464
Changelog: [Internal]
Minor followup from D78351937 - the Fusebox console notice still mentions that RNDT requires Chrome or Edge. Let's remove this mention for users opted into the standalone shell experiment.
Reviewed By: huntie
Differential Revision: D81040965
fbshipit-source-id: a290d3164261f8a1087229edfe3f69a2a9b49960
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53435
Changelog: [Internal] Support setting `enableStandaloneFuseboxShell: true` in OSS with no custom `BrowserLauncher`
Makes it possible for frameworks to enable the React Native DevTools standalone shell in open source by passing `unstable_experiments: {enableStandaloneFuseboxShell: true}` to `createDevMiddleware()`.
When this experiment is enabled:
* The RNDT shell binary will be prefetched in the background as soon as the dev server starts (into a local cache managed by [DotSlash](https://dotslash-cli.com/)).
* If prefetching is successful, then "Open DevTools" actions will be handled by launching the RNDT frontend in the standalone shell, instead of in Chrome/Edge.
* If prefetching is not successful, then we'll notify the user about the error, and "Open DevTools" will continue to be handled by Chrome/Edge, as before.
* If the user attempts to open DevTools more than once for the same app, the standalone shell will reuse the existing window (as opposed to the current behaviour of always creating a new Chrome/Edge window).
* The appropriate DevTools window will automatically foreground itself upon pausing on a breakpoint.
Reviewed By: huntie
Differential Revision: D78351937
fbshipit-source-id: 6d5baa8fa866760f1d527108cd3c42bcab68cf57
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53437
Changelog: [Internal]
The React Native DevTools standalone shell is distributed as a DotSlash file that downloads the required binaries lazily. This diff adds support in dev-middleware for a new `BrowserLauncher.unstable_prepareFuseboxShell` method that integrations can use to kick off the download early. Integrations are expected to implement this by calling the `unstable_prepareDebuggerShell` function (added to the `debugger-shell` package in D78413091).
If `BrowserLauncher.unstable_prepareFuseboxShell` returns an error, dev-middleware will fall back to the browser-based launch flow, even for users opted into the `enableStandaloneFuseboxShell` experiment.
Reviewed By: huntie
Differential Revision: D78413092
fbshipit-source-id: 6868bf07e16353fcd83337ae54c87c5a641a0f99
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53468
# Changelog: [Internal]
I've just discovered today that Chrome DevTools has a native support for `panel` query parameter, we don't need a custom one.
Reviewed By: alanleedev
Differential Revision: D81052828
fbshipit-source-id: 6f8ef5b576dbff70cabd6ab792bc0f6e615928e7
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52947
Wires up a `landingView` parameter to be passed to rn_fusebox.html that we can use to focus an arbitrary view on launch. Used from the new perf analyze scenario to open devtools on the performance panel.
Changelog:
[Android][Added] - Adds a landing view parameter to opening RNDT, enabling arbitrary view focus on launch.
Reviewed By: hoxyq
Differential Revision: D79329081
fbshipit-source-id: b1513a803f4add803100cebd08f53e59a08e64d4
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52876
Our tooling detected a couple of vulnerabilities in our package.json.
- undici
- on-headers
This change fixes these vulnerabilities.
For the on-headers vulnerabilitiy specifically, it comes from the following dependency chain:
- rn-tester > react-native-community/cli > compression > on-headers.
To fix it, we have to force the resolution to both on-headers and compression.
## Changelog:
[General][Fixed] - Fixed vulnerability on undici and on-headers
Reviewed By: cortinico
Differential Revision: D79086335
fbshipit-source-id: 44f14403196165f5f823030304102dbd0facd0ce
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52704
Stack traces for console calls are passed to the debugger when they are relative to device. (e.g. 10.0.2.2 for Android emulator)
Changelog: [android][fixed] fix stack trace linkifying failing when using Android emulator and other situations where the device and debugger have different bundle urls
Reviewed By: motiz88
Differential Revision: D78553183
fbshipit-source-id: 91d7e7ccc99d12ec7d06f4201237ecf557a46c4f
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52706
This just prepares the repo for the next branch cut.
Changelog:
[Internal] [Changed] -
Reviewed By: cipolleschi
Differential Revision: D78558445
fbshipit-source-id: 2132d560dad447b3685874438387a519587f8554
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52678
From partner feedback, there's still appetite to support Node 20.x for the next <1y of life. Lower min version to `20.19.4` (Jul 2025) and widen test matrix in CI.
Changelog:
[General][Breaking] - Our new minimum Node version is Node.js 20 (Overrides #51840)
Reviewed By: cortinico
Differential Revision: D78494491
fbshipit-source-id: c8d9dc6250cb11f8a12ca7e761b65f4a8dae9265
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52473
Shared utils that were located in the root of `scripts/` are now colocated closer to their dependencies or moved to `scripts/shared/` — simplifying the root directory layout.
Changelog: [Internal]
Reviewed By: robhogan
Differential Revision: D77873875
fbshipit-source-id: e04dba41a1ef811d32793931033fdfa93afad0cd
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52359
This is needed ahead of the 81 branch cut.
Changelog:
[Internal] - Bump all packages to 0.81.0-main
Reviewed By: huntie
Differential Revision: D77602196
fbshipit-source-id: 1b52a7d1577783d72aba8d20f98032f29ffcc7df
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/52289
The old `devtools://devtools/...` URL is **unsupported** with our modern debugger backend.
This reference was something we'd been intentionally leaving in place to preserve the old experience in Flipper — we can now remove.
Changelog: [Internal]
Reviewed By: motiz88
Differential Revision: D77368319
fbshipit-source-id: 400183e9bc477a887d66d79b412277971cf425e5
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/51840
Bumps the minimum version of Node.js in React Native to the current active LTS release (22.x, upgraded from 18.x which is now out of support).
- CI configurations are reduced from `[22, 20, 18]` to `[24, 22]`.
{F1978909878}
See https://nodejs.org/en/about/previous-releases.
Changelog:
[General][Breaking] - Our new minimum Node version is Node.js 22
Reviewed By: yungsters, cortinico
Differential Revision: D76037015
fbshipit-source-id: b6e4b3ee279a9a93d716a13297420bba73f45250
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/51788
Adds `flow` to the remaining files that are lacking it in the `packages/rn-tester` directory.
This also adds any necessary type annotations and fixes lint warnings.
Changelog:
[Internal]
Reviewed By: SamChou19815
Differential Revision: D75899307
fbshipit-source-id: 27a74ed0007b3b754446a45931c2c148312d5e3a
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/51687
Changelog: [Internal]
# Context
This is the first of several commits that aim to implement a **standalone shell for React Native DevTools**. This will be a lightweight desktop app designed to host the debugger frontend, in much the same way as we currently use Chrome or Edge. The launch flow will otherwise remain **very similar** to the one that exists today.
## What's changing for users?
1. With this commit, nothing; we're merely setting up an experiment flag (for stage 1 - Meta-internal testing) and will make separate plans for open source rollout, coordinated with our framework maintainer partners.
2. If the experiment is successful, we aim to *eventually* phase out the use of Chrome/Edge in React Native DevTools and ship the standalone shell as standard to all React Native developers. This is to enable further improvements that will rely on the standalone shell to work.
3. The first iteration of the standalone shell aims to solve some concrete pain points such as the "dead window problem" - the fact that opening DevTools multiple times for the same target will leave behind a now-dead window (that would ideally have been reused).
## This diff
We amend the `unstable_experiments` and `unstable_browserLauncher` APIs in `dev-middleware` to add basic support for launching a standalone shell based on a frontend URL and a *window key* - the latter being an opaque string that the shell process can match against previous launches in order to reuse and foreground existing windows.
We leave it up to `BrowserLauncher` implementers ( = frameworks) to provide a working implementation of `unstable_showFuseboxShell`, and do not provide one with `DefaultBrowserLauncher`. This will effectively allow us to dependency-inject the actual shell implementation at stage 1 so we don't increase the download size of React Native unnecessarily.
Reviewed By: rickhanlonii, robhogan
Differential Revision: D74904547
fbshipit-source-id: fbc6eac97923062bda8892bc130b39051845ea82
Summary:
Running with
```
DEBUG=Metro:InspectorProxy DEV=1 js1 run --no-tty-print
```
When a message larger than 100kb is send over the cdp, log it.
Changelog: [Internal]
Reviewed By: huntie
Differential Revision: D75000887
fbshipit-source-id: 6f426ed4db7ac1996c4f26461a6e0d13c096e5cd
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/51227
Standardize error messages thrown from inspector proxy when connection is closed to debugger and link to where they are used in `react-native-devtools-frontend`
Changelog: [Internal]
Reviewed By: huntie
Differential Revision: D74484316
fbshipit-source-id: 7885bc5ea41397539814f97d764c9a376ef50eaa
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50964
Address/supress ESLint warnings across the codebase, currently flagged on every PR via GitHub's "Unchanged files with check annotations" check.
{F1977480883}
Changelog: [Internal]
Reviewed By: cipolleschi
Differential Revision: D73778510
fbshipit-source-id: 91bed86877eae74fa3b9ebea71e26cdcaeee1761
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50436
Changelog: [Internal]
`is_idle` was a confusing concept that I didn't find useful when researching why disconnections happen. Instead, I'd like to know when the last communication with inspector proxy took place.
Reviewed By: hoxyq
Differential Revision: D72251072
fbshipit-source-id: 10f83bde6c8f3ed4b661bcfbef57f86f34039e5d
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50435
Changelog: [Internal] when reporting how many cdp messages passed inspector proxy, also report their total size
Reviewed By: hoxyq
Differential Revision: D72245498
fbshipit-source-id: 777274527b7e180c984b11414bec54d0e6f9d27b
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50330
Changelog: [Internal]
Make the error reported when a debugger is created for a device that does not exist generic, and not including any specific details to make them easier to aggregate
Reviewed By: hoxyq
Differential Revision: D71979796
fbshipit-source-id: 88badc51043e35ff91d7db81c5966ed5ffce9109
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50288
Add hints about why devices running in the background might not report debuggable pages:
- Taking them from background might be enough
- Force killing them to restart them properly might be needed on Android.
Changelog:
[General][Internal]
Reviewed By: huntie
Differential Revision: D71888615
fbshipit-source-id: dda54b15daa7eebd1bc28a4d327a9b3d006397a4
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/49982
In D68708899, we removed dataURI inlining of sources and source maps into `Debugger.scriptParsed` CDP notifications.
After that, all message handling for which we need to preserve order is implemented completely synchronously, so there's no need for a promise queue to preserve order.
This removes the redundant queue.
Changelog: [Internal]
Reviewed By: robhogan
Differential Revision: D71036230
fbshipit-source-id: d17fb7d06a038b379fe45b4e1c742dbf8ff12f78
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50104
Changelog:
[General][Internal] raises an event report when an attempt to open the debugger for not supported apps is made
Reviewed By: robhogan
Differential Revision: D71398802
fbshipit-source-id: 66b90a0286ee0844ced4319381e3a0581ce540b5
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/50071
Pull Request resolved: https://github.com/facebook/react-native/pull/50070
Changelog:
[General][Internal] Send code and close reasons when we close the connection to any websockets from the dev middleware
This should improve the debuggability of our code.
Reviewed By: robhogan
Differential Revision: D71314509
fbshipit-source-id: 1d6fc57a8601bcea78e95a87d423c7c46c51e799