mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
[DevTools] Rename NativeElement to HostInstance in the Bridge (#30491)
Stacked on #30490. This is in the same spirit but to clarify the difference between what is React Native vs part of any generic Host. We used to use "Native" to mean three different concepts. Now "Native" just means React Native. E.g. from the frontend's perspective the Host can be Highlighted/Inspected. However, that in turn can then be implemented as either direct DOM manipulation or commands to React Native. So frontend -> backend is "Host" but backend -> React Native is "Native" while backend -> DOM is "Web". Rename NativeElementsPanel to BuiltinElementsPanel. This isn't a React Native panel but one part of the surrounding DevTools. We refer to Host more as the thing running React itself. I.e. where the backend lives. The runtime you're inspecting. The DevTools itself needs a third term. So I went with "Builtin".
This commit is contained in:
+1
-1
@@ -108,7 +108,7 @@ export function getStackByFiberInDevAndProd(
|
||||
}
|
||||
}
|
||||
|
||||
export function supportsNativeConsoleTasks(fiber: Fiber): boolean {
|
||||
export function supportsConsoleTasks(fiber: Fiber): boolean {
|
||||
// If this Fiber supports native console.createTask then we are already running
|
||||
// inside a native async stack trace if it's active - meaning the DevTools is open.
|
||||
// Ideally we'd detect if this task was created while the DevTools was open or not.
|
||||
|
||||
Reference in New Issue
Block a user