Skip to content

Commit a66cda9

Browse files
committed
Remove "Open Debugger" action under JSC (#41535)
Summary: Pull Request resolved: #41535 ## Context **Remote JS Debugging removal** In React Native 0.73, we have deprecated Remote JS Debugging (execution of JavaScript in a separate V8 process) and also removed the Dev Menu launcher (#36754). ## This diff Follows D46187942 — this option wasn't correctly removed for Android when running JSC. This is now consistent with iOS. Changelog: [Android][Changed] "Open Debugger" is no longer available for remote JS debugging from the Dev Menu (non-Hermes). Please use `NativeDevSettings.setIsDebuggingRemotely()`. Reviewed By: blakef Differential Revision: D50555095 fbshipit-source-id: 1aeb48ab1390dc12ce300d6f321c30de5343cf0a
1 parent 02a411e commit a66cda9

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

packages/react-native/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerBase.java

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -365,15 +365,16 @@ public void onOptionSelected() {
365365
}
366366
});
367367

368-
if (mDevSettings.isDeviceDebugEnabled()) {
369-
// On-device JS debugging (CDP). Render action to open debugger frontend.
368+
if (mDevSettings.isRemoteJSDebugEnabled()) {
369+
// [Deprecated in React Native 0.73] Remote JS debugging. Handle reload
370+
// via external JS executor. This capability will be removed in a future
371+
// release.
372+
mDevSettings.setRemoteJSDebugEnabled(false);
373+
handleReloadJS();
374+
}
370375

371-
// Reset the old debugger setting so no one gets stuck.
372-
// TODO: Remove in a few weeks.
373-
if (mDevSettings.isRemoteJSDebugEnabled()) {
374-
mDevSettings.setRemoteJSDebugEnabled(false);
375-
handleReloadJS();
376-
}
376+
if (mDevSettings.isDeviceDebugEnabled() && !mDevSettings.isRemoteJSDebugEnabled()) {
377+
// On-device JS debugging (CDP). Render action to open debugger frontend.
377378
options.put(
378379
mApplicationContext.getString(R.string.catalyst_debug_open),
379380
() ->

0 commit comments

Comments
 (0)