feat(ReactNative): prioritize attribute config process function to allow processing function props (#32119)

## Summary

In react-native props that are passed as function get converted to a
boolean (`true`). This is the default pattern for event handlers in
react-native.
However, there are reasons for why you might want to opt-out of this
behavior, and instead, pass along the actual function as the prop.
Right now, there is no way to do this, and props that are functions
always get set to `true`.
The `ViewConfig` attributes already have the API for a `process`
function. I simply moved the check for the process function up, so if a
ViewConfig's prop attribute configured a process function this is always
called first.
This provides an API to opt out of the default behavior.

This is the accompanied PR for react-native:

- https://github.com/facebook/react-native/pull/48777

## How did you test this change?

<!--
Demonstrate the code is solid. Example: The exact commands you ran and
their output, screenshots / videos if the pull request changes the user
interface.
How exactly did you verify that your PR solves the issue you wanted to
solve?
  If you leave this empty, your PR will very likely be closed.
-->

I modified the code manually in a template react-native app and
confirmed its working. This is a code path you only need in very special
cases, thus it's a bit hard to provide a test for this. I recorded a
video where you can see that the changes are active and the prop is
being passed as native value.

For this I created a custom native component with a view config that
looked like this:

```js
const viewConfig = {
  uiViewClassName: 'CustomView',
  bubblingEventTypes: {},
  directEventTypes: {},
  validAttributes: {
    nativeProp: {
      process: (nativeProp) => {
		// Identity function that simply returns the prop function callback
        // to opt out of this prop being set to `true` as its a function
        return nativeProp
      },
    },
  },
}
```

https://github.com/user-attachments/assets/493534b2-a508-4142-a760-0b1b24419e19

Additionally I made sure that this doesn't conflict with any existing
view configs in react native. In general, this shouldn't be a breaking
change, as for existing view configs it didn't made a difference if you
simply set `myProp: true` or `myProp: { process: () => {...} }` because
as soon as it was detected that the prop is a function the config
wouldn't be used (which is what this PR fixes).
Probably everyone, including the react-native core components use
`myProp: true` for callback props, so this change should be fine.

DiffTrain build for [911dbd9e34](https://github.com/facebook/react/commit/911dbd9e34048b21e96f24acb837b926687aa939)
This commit is contained in:
javache
2025-06-09 03:03:13 -07:00
parent fa02f0ef85
commit a93b8dbee9
24 changed files with 112 additions and 112 deletions
+1 -1
View File
@@ -1 +1 @@
19.2.0-native-fb-d742611c-20250603
19.2.0-native-fb-911dbd9e-20250609
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<5ba333cdabfedacaf43ebe3d5bc6b1a1>>
* @generated SignedSource<<c14400fab716dfc2cc998e82f9795693>>
*/
"use strict";
@@ -404,5 +404,5 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
})();
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<4c9ba4316d4a235a6fff958e9a060379>>
* @generated SignedSource<<e63a489a1e565aeee1f75d2c73cea4a1>>
*/
"use strict";
@@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<4c9ba4316d4a235a6fff958e9a060379>>
* @generated SignedSource<<e63a489a1e565aeee1f75d2c73cea4a1>>
*/
"use strict";
@@ -203,4 +203,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<1c5268d0cdf7f429f32642769d23efbd>>
* @generated SignedSource<<74c063fdd431e982424ee3a1755935fd>>
*/
/*
@@ -27055,11 +27055,11 @@ __DEV__ &&
};
(function () {
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-d742611c-20250603" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-911dbd9e-20250609" !== 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.2.0-native-fb-d742611c-20250603\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-dom: 19.2.0-native-fb-911dbd9e-20250609\nLearn more: https://react.dev/warnings/version-mismatch")
);
})();
("function" === typeof Map &&
@@ -27096,10 +27096,10 @@ __DEV__ &&
!(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
internals.overrideHookState = overrideHookState;
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -27237,5 +27237,5 @@ __DEV__ &&
listenToAllSupportedEvents(container);
return new ReactDOMHydrationRoot(initialChildren);
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
})();
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<f938b786e9eaf90a682fa1a018b0eece>>
* @generated SignedSource<<3c71f910e9903c5be1729efa33016f70>>
*/
/*
@@ -17101,14 +17101,14 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) {
};
var isomorphicReactPackageVersion$jscomp$inline_2017 = React.version;
if (
"19.2.0-native-fb-d742611c-20250603" !==
"19.2.0-native-fb-911dbd9e-20250609" !==
isomorphicReactPackageVersion$jscomp$inline_2017
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_2017,
"19.2.0-native-fb-d742611c-20250603"
"19.2.0-native-fb-911dbd9e-20250609"
)
);
ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
@@ -17130,10 +17130,10 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
};
var internals$jscomp$inline_2536 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2537 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -17231,4 +17231,4 @@ exports.hydrateRoot = function (container, initialChildren, options) {
listenToAllSupportedEvents(container);
return new ReactDOMHydrationRoot(initialChildren);
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<d81ca51c17b4bf0dcee0ea3df4199bb3>>
* @generated SignedSource<<9fd8f5f512d50f839d908cb55b11f702>>
*/
/*
@@ -17811,14 +17811,14 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) {
};
var isomorphicReactPackageVersion$jscomp$inline_2120 = React.version;
if (
"19.2.0-native-fb-d742611c-20250603" !==
"19.2.0-native-fb-911dbd9e-20250609" !==
isomorphicReactPackageVersion$jscomp$inline_2120
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_2120,
"19.2.0-native-fb-d742611c-20250603"
"19.2.0-native-fb-911dbd9e-20250609"
)
);
ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
@@ -17840,10 +17840,10 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
};
var internals$jscomp$inline_2127 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603",
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609",
getLaneLabelMap: function () {
for (
var map = new Map(), lane = 1, index$313 = 0;
@@ -17956,4 +17956,4 @@ exports.hydrateRoot = function (container, initialChildren, options) {
listenToAllSupportedEvents(container);
return new ReactDOMHydrationRoot(initialChildren);
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<5248d2aa70fc7a785cdc31862fc337e6>>
* @generated SignedSource<<1551deabbef3877cd90e0b3853dd8bd9>>
*/
/*
@@ -27111,11 +27111,11 @@ __DEV__ &&
};
(function () {
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-d742611c-20250603" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-911dbd9e-20250609" !== 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.2.0-native-fb-d742611c-20250603\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-dom: 19.2.0-native-fb-911dbd9e-20250609\nLearn more: https://react.dev/warnings/version-mismatch")
);
})();
("function" === typeof Map &&
@@ -27152,10 +27152,10 @@ __DEV__ &&
!(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
internals.overrideHookState = overrideHookState;
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -27609,7 +27609,7 @@ __DEV__ &&
exports.useFormStatus = function () {
return resolveDispatcher().useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<b265df1a9c72f7548dc6c39cb6eac48d>>
* @generated SignedSource<<b9686bc8f6d76906c2b4f89ebbe6d3b9>>
*/
/*
@@ -17112,14 +17112,14 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) {
};
var isomorphicReactPackageVersion$jscomp$inline_2018 = React.version;
if (
"19.2.0-native-fb-d742611c-20250603" !==
"19.2.0-native-fb-911dbd9e-20250609" !==
isomorphicReactPackageVersion$jscomp$inline_2018
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_2018,
"19.2.0-native-fb-d742611c-20250603"
"19.2.0-native-fb-911dbd9e-20250609"
)
);
ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
@@ -17141,10 +17141,10 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
};
var internals$jscomp$inline_2539 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_2540 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -17395,4 +17395,4 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<f130682193151591520c7a3335b752c0>>
* @generated SignedSource<<8fcd9a7f75aaa841953faef37ccfc789>>
*/
/*
@@ -17826,14 +17826,14 @@ ReactDOMHydrationRoot.prototype.unstable_scheduleHydration = function (target) {
};
var isomorphicReactPackageVersion$jscomp$inline_2121 = React.version;
if (
"19.2.0-native-fb-d742611c-20250603" !==
"19.2.0-native-fb-911dbd9e-20250609" !==
isomorphicReactPackageVersion$jscomp$inline_2121
)
throw Error(
formatProdErrorMessage(
527,
isomorphicReactPackageVersion$jscomp$inline_2121,
"19.2.0-native-fb-d742611c-20250603"
"19.2.0-native-fb-911dbd9e-20250609"
)
);
ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
@@ -17855,10 +17855,10 @@ ReactDOMSharedInternals.findDOMNode = function (componentOrElement) {
};
var internals$jscomp$inline_2128 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-dom",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603",
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609",
getLaneLabelMap: function () {
for (
var map = new Map(), lane = 1, index$313 = 0;
@@ -18124,7 +18124,7 @@ exports.useFormState = function (action, initialState, permalink) {
exports.useFormStatus = function () {
return ReactSharedInternals.H.useHostTransitionStatus();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<c4eaed27ebedf7525d7e1e0cd0c65a74>>
* @generated SignedSource<<24b6c26de7a4e28f47062f53bcb69e94>>
*/
"use strict";
@@ -15700,10 +15700,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
internals.overrideHookState = overrideHookState;
internals.overrideHookStateDeletePath = overrideHookStateDeletePath;
@@ -15848,5 +15848,5 @@ __DEV__ &&
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
})();
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<a4440d129620f300a1127b39979649ff>>
* @generated SignedSource<<7f3c355d39e2c2c0fbce525ff62518ba>>
*/
"use strict";
@@ -9899,10 +9899,10 @@ function wrapFiber(fiber) {
}
var internals$jscomp$inline_1447 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
var hook$jscomp$inline_1448 = __REACT_DEVTOOLS_GLOBAL_HOOK__;
@@ -10038,4 +10038,4 @@ exports.unstable_batchedUpdates = function (fn, a) {
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<34c0e548bbf7ade3d65ff697a208623d>>
* @generated SignedSource<<8ccecbd6fedaba740f73313010c5db30>>
*/
"use strict";
@@ -10519,10 +10519,10 @@ function wrapFiber(fiber) {
}
var internals$jscomp$inline_1254 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-test-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603",
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609",
getLaneLabelMap: function () {
for (
var map = new Map(), lane = 1, index$155 = 0;
@@ -10673,4 +10673,4 @@ exports.unstable_batchedUpdates = function (fn, a) {
flushSyncWorkAcrossRoots_impl(0, !0));
}
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<588f0c08980f2f49b755b4c867b1a996>>
* @generated SignedSource<<039a8c3b19cb015398510d0e2f89cb64>>
*/
"use strict";
@@ -1411,7 +1411,7 @@ __DEV__ &&
exports.useTransition = function () {
return resolveDispatcher().useTransition();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<8f2a509529a81235a03cd702efa68000>>
* @generated SignedSource<<48a2d49340bf147ba9c48a40e7b96348>>
*/
"use strict";
@@ -586,4 +586,4 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<0db23886576bb76fb2636ac19412cc71>>
* @generated SignedSource<<e548accc741a4d7d28e89eacac5f97af>>
*/
"use strict";
@@ -590,7 +590,7 @@ exports.useSyncExternalStore = function (
exports.useTransition = function () {
return ReactSharedInternals.H.useTransition();
};
exports.version = "19.2.0-native-fb-d742611c-20250603";
exports.version = "19.2.0-native-fb-911dbd9e-20250609";
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&
"function" ===
typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&
@@ -1 +1 @@
d742611ce40545127032f4e221c78bf9f70eb437
911dbd9e34048b21e96f24acb837b926687aa939
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<cfd734edf94c45038dd29c1ec2b6a246>>
* @generated SignedSource<<b48ac80b717dc28f2fd7f4cd857dd0bc>>
*/
"use strict";
@@ -1324,7 +1324,9 @@ __DEV__ &&
if ((attributeConfig = validAttributes[propKey])) {
var prevProp = prevProps[propKey];
var nextProp = nextProps[propKey];
"function" === typeof nextProp &&
"function" !== typeof nextProp ||
("object" === typeof attributeConfig &&
"function" === typeof attributeConfig.process) ||
((nextProp = !0),
"function" === typeof prevProp && (prevProp = !0));
"undefined" === typeof nextProp &&
@@ -1418,14 +1420,12 @@ __DEV__ &&
if (payload && void 0 !== payload[i]) newValue = null;
else continue;
else
"function" === typeof prop
? (newValue = !0)
: "object" !== typeof attributeConfig
? (newValue = prop)
: "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff &&
(newValue = prop);
"object" === typeof attributeConfig
? "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff &&
(newValue = prop)
: (newValue = "function" === typeof prop ? !0 : prop);
void 0 !== newValue
? (payload || (payload = {}), (payload[i] = newValue))
: (payload = addNestedProperty(payload, prop, attributeConfig));
@@ -17575,10 +17575,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<b2bf10e8eb1882d1f34377206d034557>>
* @generated SignedSource<<8adf75f4a11a27610f361c90fed8b54d>>
*/
"use strict";
@@ -1443,7 +1443,9 @@ function diffProperties(updatePayload, prevProps, nextProps, validAttributes) {
if ((attributeConfig = validAttributes[propKey])) {
var prevProp = prevProps[propKey];
var nextProp = nextProps[propKey];
"function" === typeof nextProp &&
"function" !== typeof nextProp ||
("object" === typeof attributeConfig &&
"function" === typeof attributeConfig.process) ||
((nextProp = !0), "function" === typeof prevProp && (prevProp = !0));
"undefined" === typeof nextProp &&
((nextProp = null),
@@ -1536,13 +1538,11 @@ function addNestedProperty(payload, props, validAttributes) {
if (payload && void 0 !== payload[i]) newValue = null;
else continue;
else
"function" === typeof prop
? (newValue = !0)
: "object" !== typeof attributeConfig
? (newValue = prop)
: "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff && (newValue = prop);
"object" === typeof attributeConfig
? "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff && (newValue = prop)
: (newValue = "function" === typeof prop ? !0 : prop);
void 0 !== newValue
? (payload || (payload = {}), (payload[i] = newValue))
: (payload = addNestedProperty(payload, prop, attributeConfig));
@@ -11258,10 +11258,10 @@ batchedUpdatesImpl = function (fn, a) {
var roots = new Map(),
internals$jscomp$inline_1263 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1263.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<bac352e28578d9c8a31afb821bc5d95a>>
* @generated SignedSource<<9f9ec1f87fad9779093a3799837730aa>>
*/
"use strict";
@@ -1447,7 +1447,9 @@ function diffProperties(updatePayload, prevProps, nextProps, validAttributes) {
if ((attributeConfig = validAttributes[propKey])) {
var prevProp = prevProps[propKey];
var nextProp = nextProps[propKey];
"function" === typeof nextProp &&
"function" !== typeof nextProp ||
("object" === typeof attributeConfig &&
"function" === typeof attributeConfig.process) ||
((nextProp = !0), "function" === typeof prevProp && (prevProp = !0));
"undefined" === typeof nextProp &&
((nextProp = null),
@@ -1540,13 +1542,11 @@ function addNestedProperty(payload, props, validAttributes) {
if (payload && void 0 !== payload[i]) newValue = null;
else continue;
else
"function" === typeof prop
? (newValue = !0)
: "object" !== typeof attributeConfig
? (newValue = prop)
: "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff && (newValue = prop);
"object" === typeof attributeConfig
? "function" === typeof attributeConfig.process
? (newValue = attributeConfig.process(prop))
: "function" === typeof attributeConfig.diff && (newValue = prop)
: (newValue = "function" === typeof prop ? !0 : prop);
void 0 !== newValue
? (payload || (payload = {}), (payload[i] = newValue))
: (payload = addNestedProperty(payload, prop, attributeConfig));
@@ -11962,10 +11962,10 @@ batchedUpdatesImpl = function (fn, a) {
var roots = new Map(),
internals$jscomp$inline_1364 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1364.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<70277df0f31abb75e43baa69bee13880>>
* @generated SignedSource<<15c47771617b931e01c5b1365482f793>>
*/
"use strict";
@@ -17651,11 +17651,11 @@ __DEV__ &&
shouldSuspendImpl = newShouldSuspendImpl;
};
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-d742611c-20250603" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-911dbd9e-20250609" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-d742611c-20250603\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-911dbd9e-20250609\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -17681,10 +17681,10 @@ __DEV__ &&
(function () {
var internals = {
bundleType: 1,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<d94053e6386722a07b4b7aca4e4d5818>>
* @generated SignedSource<<ebb8fe874136a9d0cf6d06f64b5ab15d>>
*/
"use strict";
@@ -11215,11 +11215,11 @@ function updateContainer(element, container, parentComponent, callback) {
return lane;
}
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-d742611c-20250603" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-911dbd9e-20250609" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-d742611c-20250603\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-911dbd9e-20250609\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -11269,10 +11269,10 @@ batchedUpdatesImpl = function (fn, a) {
var roots = new Map(),
internals$jscomp$inline_1307 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1307.rendererConfig = extraDevToolsConfig);
@@ -7,7 +7,7 @@
* @noflow
* @nolint
* @preventMunge
* @generated SignedSource<<438ba17a739f1c380cb9f51816737bfe>>
* @generated SignedSource<<8d8a736069c4494eacd90534d47db1f1>>
*/
"use strict";
@@ -11917,11 +11917,11 @@ function updateContainer(element, container, parentComponent, callback) {
return lane;
}
var isomorphicReactPackageVersion = React.version;
if ("19.2.0-native-fb-d742611c-20250603" !== isomorphicReactPackageVersion)
if ("19.2.0-native-fb-911dbd9e-20250609" !== isomorphicReactPackageVersion)
throw Error(
'Incompatible React versions: The "react" and "react-native-renderer" packages must have the exact same version. Instead got:\n - react: ' +
(isomorphicReactPackageVersion +
"\n - react-native-renderer: 19.2.0-native-fb-d742611c-20250603\nLearn more: https://react.dev/warnings/version-mismatch")
"\n - react-native-renderer: 19.2.0-native-fb-911dbd9e-20250609\nLearn more: https://react.dev/warnings/version-mismatch")
);
if (
"function" !==
@@ -11971,10 +11971,10 @@ batchedUpdatesImpl = function (fn, a) {
var roots = new Map(),
internals$jscomp$inline_1408 = {
bundleType: 0,
version: "19.2.0-native-fb-d742611c-20250603",
version: "19.2.0-native-fb-911dbd9e-20250609",
rendererPackageName: "react-native-renderer",
currentDispatcherRef: ReactSharedInternals,
reconcilerVersion: "19.2.0-native-fb-d742611c-20250603"
reconcilerVersion: "19.2.0-native-fb-911dbd9e-20250609"
};
null !== extraDevToolsConfig &&
(internals$jscomp$inline_1408.rendererConfig = extraDevToolsConfig);
@@ -1,7 +1,7 @@
{
"name": "eslint-plugin-react-hooks",
"description": "ESLint rules for React Hooks",
"version": "0.0.0-experimental-d742611c-20250603",
"version": "0.0.0-experimental-911dbd9e-20250609",
"repository": {
"type": "git",
"url": "https://github.com/facebook/react.git",