Skip to content

Commit e591dc4

Browse files
committed
Fix Flow types of useEffectEvent (#26468)
## Summary Just copied the types over from the internal types. Type error was hidden by overly broad FlowFixMe. With `$FlowFixMe[not-a-function]` we would've seen the actual issue: ``` Cannot return `dispatcher.useEffectEvent(...)` because `T` [1] is incompatible with undefined [2].Flow(incompatible-return) ``` ## How did you test this change? - [x] yarn flow dom-node - [x] CI DiffTrain build for commit d12bdcd.
1 parent 57fd488 commit e591dc4

File tree

13 files changed

+23
-23
lines changed

13 files changed

+23
-23
lines changed

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-dev.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -23743,7 +23743,7 @@ function createFiberRoot(
2374323743
return root;
2374423744
}
2374523745

23746-
var ReactVersion = "18.3.0-next-73b6435ca-20230324";
23746+
var ReactVersion = "18.3.0-next-d12bdcda6-20230325";
2374723747

2374823748
// Might add PROFILE later.
2374923749

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-prod.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -8623,7 +8623,7 @@ var devToolsConfig$jscomp$inline_1002 = {
86238623
throw Error("TestRenderer does not support findFiberByHostInstance()");
86248624
},
86258625
bundleType: 0,
8626-
version: "18.3.0-next-73b6435ca-20230324",
8626+
version: "18.3.0-next-d12bdcda6-20230325",
86278627
rendererPackageName: "react-test-renderer"
86288628
};
86298629
var internals$jscomp$inline_1193 = {
@@ -8654,7 +8654,7 @@ var internals$jscomp$inline_1193 = {
86548654
scheduleRoot: null,
86558655
setRefreshHandler: null,
86568656
getCurrentFiber: null,
8657-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
8657+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
86588658
};
86598659
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
86608660
var hook$jscomp$inline_1194 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react-test-renderer/cjs/ReactTestRenderer-profiling.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9048,7 +9048,7 @@ var devToolsConfig$jscomp$inline_1045 = {
90489048
throw Error("TestRenderer does not support findFiberByHostInstance()");
90499049
},
90509050
bundleType: 0,
9051-
version: "18.3.0-next-73b6435ca-20230324",
9051+
version: "18.3.0-next-d12bdcda6-20230325",
90529052
rendererPackageName: "react-test-renderer"
90539053
};
90549054
var internals$jscomp$inline_1234 = {
@@ -9079,7 +9079,7 @@ var internals$jscomp$inline_1234 = {
90799079
scheduleRoot: null,
90809080
setRefreshHandler: null,
90819081
getCurrentFiber: null,
9082-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
9082+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
90839083
};
90849084
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
90859085
var hook$jscomp$inline_1235 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-dev.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ if (
2727
}
2828
"use strict";
2929

30-
var ReactVersion = "18.3.0-next-73b6435ca-20230324";
30+
var ReactVersion = "18.3.0-next-d12bdcda6-20230325";
3131

3232
// ATTENTION
3333
// When adding new symbols to this file,
@@ -2071,22 +2071,22 @@ function useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot) {
20712071
);
20722072
}
20732073
function useCacheRefresh() {
2074-
var dispatcher = resolveDispatcher(); // $FlowFixMe This is unstable, thus optional
2074+
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
20752075

20762076
return dispatcher.useCacheRefresh();
20772077
}
20782078
function use(usable) {
2079-
var dispatcher = resolveDispatcher(); // $FlowFixMe This is unstable, thus optional
2079+
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
20802080

20812081
return dispatcher.use(usable);
20822082
}
20832083
function useMemoCache(size) {
2084-
var dispatcher = resolveDispatcher(); // $FlowFixMe This is unstable, thus optional
2084+
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
20852085

20862086
return dispatcher.useMemoCache(size);
20872087
}
20882088
function useEffectEvent(callback) {
2089-
var dispatcher = resolveDispatcher(); // $FlowFixMe This is unstable, thus optional
2089+
var dispatcher = resolveDispatcher(); // $FlowFixMe[not-a-function] This is unstable, thus optional
20902090

20912091
return dispatcher.useEffectEvent(callback);
20922092
}

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-prod.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -639,4 +639,4 @@ exports.useSyncExternalStore = function (
639639
);
640640
};
641641
exports.useTransition = useTransition;
642-
exports.version = "18.3.0-next-73b6435ca-20230324";
642+
exports.version = "18.3.0-next-d12bdcda6-20230325";

compiled-rn/facebook-fbsource/xplat/js/RKJSModules/vendor/react/cjs/React-profiling.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,7 @@ exports.useSyncExternalStore = function (
642642
);
643643
};
644644
exports.useTransition = useTransition;
645-
exports.version = "18.3.0-next-73b6435ca-20230324";
645+
exports.version = "18.3.0-next-d12bdcda6-20230325";
646646

647647
/* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */
648648
if (
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
73b6435ca4e0c3ae3aac8126509a82420a84f0d7
1+
d12bdcda69afd219f4d91cbd60d6fae2a375d35b

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-dev.fb.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -27008,7 +27008,7 @@ function createFiberRoot(
2700827008
return root;
2700927009
}
2701027010

27011-
var ReactVersion = "18.3.0-next-73b6435ca-20230324";
27011+
var ReactVersion = "18.3.0-next-d12bdcda6-20230325";
2701227012

2701327013
function createPortal$1(
2701427014
children,

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-prod.fb.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9490,7 +9490,7 @@ var roots = new Map(),
94909490
devToolsConfig$jscomp$inline_1022 = {
94919491
findFiberByHostInstance: getInstanceFromNode,
94929492
bundleType: 0,
9493-
version: "18.3.0-next-73b6435ca-20230324",
9493+
version: "18.3.0-next-d12bdcda6-20230325",
94949494
rendererPackageName: "react-native-renderer",
94959495
rendererConfig: {
94969496
getInspectorDataForViewTag: function () {
@@ -9532,7 +9532,7 @@ var internals$jscomp$inline_1268 = {
95329532
scheduleRoot: null,
95339533
setRefreshHandler: null,
95349534
getCurrentFiber: null,
9535-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
9535+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
95369536
};
95379537
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
95389538
var hook$jscomp$inline_1269 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactFabric-profiling.fb.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -10198,7 +10198,7 @@ var roots = new Map(),
1019810198
devToolsConfig$jscomp$inline_1101 = {
1019910199
findFiberByHostInstance: getInstanceFromNode,
1020010200
bundleType: 0,
10201-
version: "18.3.0-next-73b6435ca-20230324",
10201+
version: "18.3.0-next-d12bdcda6-20230325",
1020210202
rendererPackageName: "react-native-renderer",
1020310203
rendererConfig: {
1020410204
getInspectorDataForViewTag: function () {
@@ -10253,7 +10253,7 @@ var roots = new Map(),
1025310253
scheduleRoot: null,
1025410254
setRefreshHandler: null,
1025510255
getCurrentFiber: null,
10256-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
10256+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
1025710257
});
1025810258
exports.createPortal = function (children, containerTag) {
1025910259
return createPortal$1(

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-dev.fb.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -27548,7 +27548,7 @@ function createFiberRoot(
2754827548
return root;
2754927549
}
2755027550

27551-
var ReactVersion = "18.3.0-next-73b6435ca-20230324";
27551+
var ReactVersion = "18.3.0-next-d12bdcda6-20230325";
2755227552

2755327553
function createPortal$1(
2755427554
children,

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-prod.fb.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -9746,7 +9746,7 @@ var roots = new Map(),
97469746
devToolsConfig$jscomp$inline_1081 = {
97479747
findFiberByHostInstance: getInstanceFromTag,
97489748
bundleType: 0,
9749-
version: "18.3.0-next-73b6435ca-20230324",
9749+
version: "18.3.0-next-d12bdcda6-20230325",
97509750
rendererPackageName: "react-native-renderer",
97519751
rendererConfig: {
97529752
getInspectorDataForViewTag: function () {
@@ -9788,7 +9788,7 @@ var internals$jscomp$inline_1334 = {
97889788
scheduleRoot: null,
97899789
setRefreshHandler: null,
97909790
getCurrentFiber: null,
9791-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
9791+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
97929792
};
97939793
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
97949794
var hook$jscomp$inline_1335 = __REACT_DEVTOOLS_GLOBAL_HOOK__;

compiled-rn/facebook-fbsource/xplat/js/react-native-github/Libraries/Renderer/implementations/ReactNativeRenderer-profiling.fb.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -10454,7 +10454,7 @@ var roots = new Map(),
1045410454
devToolsConfig$jscomp$inline_1160 = {
1045510455
findFiberByHostInstance: getInstanceFromTag,
1045610456
bundleType: 0,
10457-
version: "18.3.0-next-73b6435ca-20230324",
10457+
version: "18.3.0-next-d12bdcda6-20230325",
1045810458
rendererPackageName: "react-native-renderer",
1045910459
rendererConfig: {
1046010460
getInspectorDataForViewTag: function () {
@@ -10509,7 +10509,7 @@ var roots = new Map(),
1050910509
scheduleRoot: null,
1051010510
setRefreshHandler: null,
1051110511
getCurrentFiber: null,
10512-
reconcilerVersion: "18.3.0-next-73b6435ca-20230324"
10512+
reconcilerVersion: "18.3.0-next-d12bdcda6-20230325"
1051310513
});
1051410514
exports.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = {
1051510515
computeComponentStackForErrorReporting: function (reactTag) {

0 commit comments

Comments
 (0)