Skip to content

Commit 6acd079

Browse files
sebmarkbagegnoff
authored andcommitted
Remove old field from internals
1 parent af3c909 commit 6acd079

File tree

2 files changed

+3
-17
lines changed

2 files changed

+3
-17
lines changed

packages/react/src/ReactSharedInternalsClient.js

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,13 @@
1010
import type {Dispatcher} from 'react-reconciler/src/ReactInternalTypes';
1111
import type {AsyncDispatcher} from 'react-reconciler/src/ReactInternalTypes';
1212
import type {BatchConfigTransition} from 'react-reconciler/src/ReactFiberTracingMarkerComponent';
13-
import type {Fiber} from 'react-reconciler/src/ReactInternalTypes';
14-
15-
import {disableStringRefs} from 'shared/ReactFeatureFlags';
1613

1714
export type SharedStateClient = {
1815
H: null | Dispatcher, // ReactCurrentDispatcher for Hooks
1916
A: null | AsyncDispatcher, // ReactCurrentCache for Cache
2017
T: null | BatchConfigTransition, // ReactCurrentBatchConfig for Transitions
2118

22-
// DEV-only-ish
23-
owner: null | Fiber, // ReactCurrentOwner is Fiber on the Client, null in Fizz. Flight uses SharedStateServer.
19+
// DEV-only
2420

2521
// ReactCurrentActQueue
2622
actQueue: null | Array<RendererTask>,
@@ -51,10 +47,6 @@ const ReactSharedInternals: SharedStateClient = ({
5147
T: null,
5248
}: any);
5349

54-
if (__DEV__ || !disableStringRefs) {
55-
ReactSharedInternals.owner = null;
56-
}
57-
5850
if (__DEV__) {
5951
ReactSharedInternals.actQueue = null;
6052
ReactSharedInternals.isBatchingLegacy = false;

packages/react/src/ReactSharedInternalsServer.js

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99

1010
import type {Dispatcher} from 'react-reconciler/src/ReactInternalTypes';
1111
import type {AsyncDispatcher} from 'react-reconciler/src/ReactInternalTypes';
12-
import type {ReactComponentInfo} from 'shared/ReactTypes';
1312

1413
import type {
1514
Reference,
@@ -24,7 +23,7 @@ import {
2423
TaintRegistryPendingRequests,
2524
} from './ReactTaintRegistry';
2625

27-
import {disableStringRefs, enableTaint} from 'shared/ReactFeatureFlags';
26+
import {enableTaint} from 'shared/ReactFeatureFlags';
2827

2928
export type SharedStateServer = {
3029
H: null | Dispatcher, // ReactCurrentDispatcher for Hooks
@@ -36,8 +35,7 @@ export type SharedStateServer = {
3635
TaintRegistryByteLengths: Set<number>,
3736
TaintRegistryPendingRequests: Set<RequestCleanupQueue>,
3837

39-
// DEV-only-ish
40-
owner: null | ReactComponentInfo, // ReactCurrentOwner is ReactComponentInfo in Flight, null in Fizz. Fiber/Fizz uses SharedStateClient.
38+
// DEV-only
4139

4240
// ReactDebugCurrentFrame
4341
setExtraStackFrame: (stack: null | string) => void,
@@ -60,10 +58,6 @@ if (enableTaint) {
6058
TaintRegistryPendingRequests;
6159
}
6260

63-
if (__DEV__ || !disableStringRefs) {
64-
ReactSharedInternals.owner = null;
65-
}
66-
6761
if (__DEV__) {
6862
let currentExtraStackFrame = (null: null | string);
6963
ReactSharedInternals.setExtraStackFrame = function (stack: null | string) {

0 commit comments

Comments
 (0)