Skip to content

Commit

Permalink
Remove enableRefAsProp feature flag (#30346)
Browse files Browse the repository at this point in the history
The flag is fully rolled out.

DiffTrain build for [07aa494](07aa494)
  • Loading branch information
kassens committed Nov 4, 2024
1 parent eeb3328 commit c53145c
Show file tree
Hide file tree
Showing 25 changed files with 1,116 additions and 1,307 deletions.
2 changes: 1 addition & 1 deletion compiled-rn/VERSION_NATIVE_FB
Original file line number Diff line number Diff line change
@@ -1 +1 @@
19.0.0-native-fb-ea3ac586-20241031
19.0.0-native-fb-07aa4944-20241104
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<fe2a5887890fd9ac0c7e12bbbe65fde3>>
* @generated SignedSource<<dcb2fe275d42581e440eab19f4f48f20>>
*/

"use strict";
Expand Down Expand Up @@ -420,5 +420,5 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.0.0-native-fb-ea3ac586-20241031";
exports.version = "19.0.0-native-fb-07aa4944-20241104";
})();
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<1cb77e72c96250d4d97fa3f50697ea38>>
* @generated SignedSource<<772ea4b36b8b994c3826632a6ac860ea>>
*/

"use strict";
Expand Down Expand Up @@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-native-fb-ea3ac586-20241031";
exports.version = "19.0.0-native-fb-07aa4944-20241104";
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<1cb77e72c96250d4d97fa3f50697ea38>>
* @generated SignedSource<<772ea4b36b8b994c3826632a6ac860ea>>
*/

"use strict";
Expand Down Expand Up @@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.0.0-native-fb-ea3ac586-20241031";
exports.version = "19.0.0-native-fb-07aa4944-20241104";
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<5c3370bf9d23dea134827436a14c995a>>
* @generated SignedSource<<abdb2c36b62c6c0ae8f60c39c966e5d9>>
*/

/*
Expand Down Expand Up @@ -4568,9 +4568,9 @@ __DEV__ &&
null === thenableState$1 && (thenableState$1 = createThenableState());
return trackUsedThenable(thenableState$1, thenable, index);
}
function coerceRef(returnFiber, current, workInProgress, element) {
returnFiber = element.props.ref;
workInProgress.ref = void 0 !== returnFiber ? returnFiber : null;
function coerceRef(workInProgress, element) {
element = element.props.ref;
workInProgress.ref = void 0 !== element ? element : null;
}
function throwOnInvalidObjectType(returnFiber, newChild) {
if (newChild.$$typeof === REACT_LEGACY_ELEMENT_TYPE)
Expand Down Expand Up @@ -4719,18 +4719,18 @@ __DEV__ &&
callLazyInitInDEV(elementType) === current.type))
)
return (
(lanes = useFiber(current, element.props)),
coerceRef(returnFiber, current, lanes, element),
(lanes.return = returnFiber),
(lanes._debugOwner = element._owner),
(lanes._debugInfo = currentDebugInfo),
lanes
(current = useFiber(current, element.props)),
coerceRef(current, element),
(current.return = returnFiber),
(current._debugOwner = element._owner),
(current._debugInfo = currentDebugInfo),
current
);
lanes = createFiberFromElement(element, returnFiber.mode, lanes);
coerceRef(returnFiber, current, lanes, element);
lanes.return = returnFiber;
lanes._debugInfo = currentDebugInfo;
return lanes;
current = createFiberFromElement(element, returnFiber.mode, lanes);
coerceRef(current, element);
current.return = returnFiber;
current._debugInfo = currentDebugInfo;
return current;
}
function updatePortal(returnFiber, current, portal, lanes) {
if (
Expand Down Expand Up @@ -4795,7 +4795,7 @@ __DEV__ &&
returnFiber.mode,
lanes
)),
coerceRef(returnFiber, null, lanes, newChild),
coerceRef(lanes, newChild),
(lanes.return = returnFiber),
(returnFiber = pushDebugInfo(newChild._debugInfo)),
(lanes._debugInfo = currentDebugInfo),
Expand Down Expand Up @@ -5310,80 +5310,72 @@ __DEV__ &&
case REACT_ELEMENT_TYPE:
var prevDebugInfo = pushDebugInfo(newChild._debugInfo);
a: {
for (
var key = newChild.key, child = currentFirstChild;
null !== child;

) {
if (child.key === key) {
for (var key = newChild.key; null !== currentFirstChild; ) {
if (currentFirstChild.key === key) {
key = newChild.type;
if (key === REACT_FRAGMENT_TYPE) {
if (7 === child.tag) {
deleteRemainingChildren(returnFiber, child.sibling);
currentFirstChild = useFiber(
child,
newChild.props.children
if (7 === currentFirstChild.tag) {
deleteRemainingChildren(
returnFiber,
currentFirstChild.sibling
);
currentFirstChild.return = returnFiber;
currentFirstChild._debugOwner = newChild._owner;
currentFirstChild._debugInfo = currentDebugInfo;
validateFragmentProps(
newChild,
lanes = useFiber(
currentFirstChild,
returnFiber
newChild.props.children
);
returnFiber = currentFirstChild;
lanes.return = returnFiber;
lanes._debugOwner = newChild._owner;
lanes._debugInfo = currentDebugInfo;
validateFragmentProps(newChild, lanes, returnFiber);
returnFiber = lanes;
break a;
}
} else if (
child.elementType === key ||
isCompatibleFamilyForHotReloading(child, newChild) ||
currentFirstChild.elementType === key ||
isCompatibleFamilyForHotReloading(
currentFirstChild,
newChild
) ||
("object" === typeof key &&
null !== key &&
key.$$typeof === REACT_LAZY_TYPE &&
callLazyInitInDEV(key) === child.type)
callLazyInitInDEV(key) === currentFirstChild.type)
) {
deleteRemainingChildren(returnFiber, child.sibling);
currentFirstChild = useFiber(child, newChild.props);
coerceRef(
deleteRemainingChildren(
returnFiber,
child,
currentFirstChild,
newChild
currentFirstChild.sibling
);
currentFirstChild.return = returnFiber;
currentFirstChild._debugOwner = newChild._owner;
currentFirstChild._debugInfo = currentDebugInfo;
returnFiber = currentFirstChild;
lanes = useFiber(currentFirstChild, newChild.props);
coerceRef(lanes, newChild);
lanes.return = returnFiber;
lanes._debugOwner = newChild._owner;
lanes._debugInfo = currentDebugInfo;
returnFiber = lanes;
break a;
}
deleteRemainingChildren(returnFiber, child);
deleteRemainingChildren(returnFiber, currentFirstChild);
break;
} else deleteChild(returnFiber, child);
child = child.sibling;
} else deleteChild(returnFiber, currentFirstChild);
currentFirstChild = currentFirstChild.sibling;
}
newChild.type === REACT_FRAGMENT_TYPE
? ((currentFirstChild = createFiberFromFragment(
? ((lanes = createFiberFromFragment(
newChild.props.children,
returnFiber.mode,
lanes,
newChild.key
)),
(currentFirstChild.return = returnFiber),
(currentFirstChild._debugOwner = returnFiber),
(currentFirstChild._debugInfo = currentDebugInfo),
validateFragmentProps(
newChild,
currentFirstChild,
returnFiber
),
(returnFiber = currentFirstChild))
(lanes.return = returnFiber),
(lanes._debugOwner = returnFiber),
(lanes._debugInfo = currentDebugInfo),
validateFragmentProps(newChild, lanes, returnFiber),
(returnFiber = lanes))
: ((lanes = createFiberFromElement(
newChild,
returnFiber.mode,
lanes
)),
coerceRef(returnFiber, currentFirstChild, lanes, newChild),
coerceRef(lanes, newChild),
(lanes.return = returnFiber),
(lanes._debugInfo = currentDebugInfo),
(returnFiber = lanes));
Expand Down Expand Up @@ -5411,12 +5403,12 @@ __DEV__ &&
returnFiber,
currentFirstChild.sibling
);
currentFirstChild = useFiber(
lanes = useFiber(
currentFirstChild,
prevDebugInfo.children || []
);
currentFirstChild.return = returnFiber;
returnFiber = currentFirstChild;
lanes.return = returnFiber;
returnFiber = lanes;
break a;
} else {
deleteRemainingChildren(returnFiber, currentFirstChild);
Expand All @@ -5425,13 +5417,13 @@ __DEV__ &&
else deleteChild(returnFiber, currentFirstChild);
currentFirstChild = currentFirstChild.sibling;
}
currentFirstChild = createFiberFromPortal(
lanes = createFiberFromPortal(
prevDebugInfo,
returnFiber.mode,
lanes
);
currentFirstChild.return = returnFiber;
returnFiber = currentFirstChild;
lanes.return = returnFiber;
returnFiber = lanes;
}
return placeSingleChild(returnFiber);
case REACT_LAZY_TYPE:
Expand Down Expand Up @@ -5462,26 +5454,27 @@ __DEV__ &&
);
if (getIteratorFn(newChild)) {
prevDebugInfo = pushDebugInfo(newChild._debugInfo);
child = getIteratorFn(newChild);
if ("function" !== typeof child)
key = getIteratorFn(newChild);
if ("function" !== typeof key)
throw Error(
"An object is not an iterable. This error is likely caused by a bug in React. Please file an issue."
);
key = child.call(newChild);
if (key === newChild) {
var newChildren = key.call(newChild);
if (newChildren === newChild) {
if (
0 !== returnFiber.tag ||
"[object GeneratorFunction]" !==
Object.prototype.toString.call(returnFiber.type) ||
"[object Generator]" !== Object.prototype.toString.call(key)
"[object Generator]" !==
Object.prototype.toString.call(newChildren)
)
didWarnAboutGenerators ||
error$jscomp$0(
"Using Iterators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. You can also use an Iterable that can iterate multiple times over the same items."
),
(didWarnAboutGenerators = !0);
} else
newChild.entries !== child ||
newChild.entries !== key ||
didWarnAboutMaps ||
(error$jscomp$0(
"Using Maps as children is not supported. Use an array of keyed ReactElements instead."
Expand All @@ -5490,7 +5483,7 @@ __DEV__ &&
returnFiber = reconcileChildrenIterator(
returnFiber,
currentFirstChild,
key,
newChildren,
lanes
);
currentDebugInfo = prevDebugInfo;
Expand Down Expand Up @@ -5529,22 +5522,19 @@ __DEV__ &&
returnFiber,
currentFirstChild.sibling
),
(currentFirstChild = useFiber(
currentFirstChild,
prevDebugInfo
)),
(currentFirstChild.return = returnFiber),
(returnFiber = currentFirstChild))
(lanes = useFiber(currentFirstChild, prevDebugInfo)),
(lanes.return = returnFiber),
(returnFiber = lanes))
: (deleteRemainingChildren(returnFiber, currentFirstChild),
(currentFirstChild = createFiberFromText(
(lanes = createFiberFromText(
prevDebugInfo,
returnFiber.mode,
lanes
)),
(currentFirstChild.return = returnFiber),
(currentFirstChild._debugOwner = returnFiber),
(currentFirstChild._debugInfo = currentDebugInfo),
(returnFiber = currentFirstChild)),
(lanes.return = returnFiber),
(lanes._debugOwner = returnFiber),
(lanes._debugInfo = currentDebugInfo),
(returnFiber = lanes)),
placeSingleChild(returnFiber)
);
"function" === typeof newChild &&
Expand Down Expand Up @@ -25347,11 +25337,11 @@ __DEV__ &&
};
(function () {
var isomorphicReactPackageVersion = React.version;
if ("19.0.0-native-fb-ea3ac586-20241031" !== isomorphicReactPackageVersion)
if ("19.0.0-native-fb-07aa4944-20241104" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-dom: 19.0.0-native-fb-ea3ac586-20241031\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-dom: 19.0.0-native-fb-07aa4944-20241104\nLearn more: https://react.dev/warnings/version-mismatch")
);
})();
("function" === typeof Map &&
Expand Down Expand Up @@ -25388,11 +25378,11 @@ __DEV__ &&
!(function () {
var internals = {
bundleType: 1,
version: "19.0.0-native-fb-ea3ac586-20241031",
version: "19.0.0-native-fb-07aa4944-20241104",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
findFiberByHostInstance: getClosestInstanceFromNode,
reconcilerVersion: "19.0.0-native-fb-ea3ac586-20241031"
reconcilerVersion: "19.0.0-native-fb-07aa4944-20241104"
};
internals.overrideHookState = overrideHookState;
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
Expand Down Expand Up @@ -25536,5 +25526,5 @@ __DEV__ &&
listenToAllSupportedEvents(container);
return new ReactDOMHydrationRoot(initialChildren);
};
exports.version = "19.0.0-native-fb-ea3ac586-20241031";
exports.version = "19.0.0-native-fb-07aa4944-20241104";
})();
Loading

0 comments on commit c53145c

Please sign in to comment.