mirror of
https://github.com/zebrajr/react.git
synced 2025-12-06 00:20:04 +01:00
Update Flow to 0.261 (#34255)
- 0.261 required to pull out a constant to preserve refinement - 0.259 needed some updated suppressions for hacky stuff
This commit is contained in:
parent
d5586e2059
commit
d73b6f1110
|
|
@ -73,8 +73,8 @@
|
|||
"eslint-plugin-react-internal": "link:./scripts/eslint-rules",
|
||||
"fbjs-scripts": "^3.0.1",
|
||||
"filesize": "^6.0.1",
|
||||
"flow-bin": "^0.258",
|
||||
"flow-remove-types": "^2.258",
|
||||
"flow-bin": "^0.261",
|
||||
"flow-remove-types": "^2.261",
|
||||
"glob": "^7.1.6",
|
||||
"glob-stream": "^6.1.0",
|
||||
"google-closure-compiler": "^20230206.0.0",
|
||||
|
|
|
|||
|
|
@ -1183,7 +1183,7 @@ function bind(this: Function): Function {
|
|||
const referenceClosure = knownServerReferences.get(this);
|
||||
|
||||
if (!referenceClosure) {
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
return FunctionBind.apply(this, arguments);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2991,7 +2991,8 @@ FragmentInstance.prototype.unobserveUsing = function (
|
|||
this: FragmentInstanceType,
|
||||
observer: IntersectionObserver | ResizeObserver,
|
||||
): void {
|
||||
if (this._observers === null || !this._observers.has(observer)) {
|
||||
const observers = this._observers;
|
||||
if (observers === null || !observers.has(observer)) {
|
||||
if (__DEV__) {
|
||||
console.error(
|
||||
'You are calling unobserveUsing() with an observer that is not being observed with this fragment ' +
|
||||
|
|
@ -2999,7 +3000,7 @@ FragmentInstance.prototype.unobserveUsing = function (
|
|||
);
|
||||
}
|
||||
} else {
|
||||
this._observers.delete(observer);
|
||||
observers.delete(observer);
|
||||
traverseFragmentInstance(this._fragmentFiber, unobserveChild, observer);
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -651,7 +651,8 @@ FragmentInstance.prototype.unobserveUsing = function (
|
|||
this: FragmentInstanceType,
|
||||
observer: IntersectionObserver,
|
||||
): void {
|
||||
if (this._observers === null || !this._observers.has(observer)) {
|
||||
const observers = this._observers;
|
||||
if (observers === null || !observers.has(observer)) {
|
||||
if (__DEV__) {
|
||||
console.error(
|
||||
'You are calling unobserveUsing() with an observer that is not being observed with this fragment ' +
|
||||
|
|
@ -659,7 +660,7 @@ FragmentInstance.prototype.unobserveUsing = function (
|
|||
);
|
||||
}
|
||||
} else {
|
||||
this._observers.delete(observer);
|
||||
observers.delete(observer);
|
||||
traverseFragmentInstance(this._fragmentFiber, unobserveChild, observer);
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ const FunctionBind = Function.prototype.bind;
|
|||
// $FlowFixMe[method-unbinding]
|
||||
const ArraySlice = Array.prototype.slice;
|
||||
function bind(this: ServerReference<any>): any {
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
const newFn = FunctionBind.apply(this, arguments);
|
||||
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
||||
if (__DEV__) {
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ const FunctionBind = Function.prototype.bind;
|
|||
// $FlowFixMe[method-unbinding]
|
||||
const ArraySlice = Array.prototype.slice;
|
||||
function bind(this: ServerReference<any>): any {
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
const newFn = FunctionBind.apply(this, arguments);
|
||||
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
||||
if (__DEV__) {
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ const FunctionBind = Function.prototype.bind;
|
|||
// $FlowFixMe[method-unbinding]
|
||||
const ArraySlice = Array.prototype.slice;
|
||||
function bind(this: ServerReference<any>): any {
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
const newFn = FunctionBind.apply(this, arguments);
|
||||
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
||||
if (__DEV__) {
|
||||
|
|
|
|||
|
|
@ -63,8 +63,7 @@ const FunctionBind = Function.prototype.bind;
|
|||
// $FlowFixMe[method-unbinding]
|
||||
const ArraySlice = Array.prototype.slice;
|
||||
function bind(this: ServerReference<any>): any {
|
||||
// $FlowFixMe[unsupported-syntax]
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
const newFn = FunctionBind.apply(this, arguments);
|
||||
if (this.$$typeof === SERVER_REFERENCE_TAG) {
|
||||
if (__DEV__) {
|
||||
|
|
|
|||
|
|
@ -408,7 +408,7 @@ function patchConsole(consoleInst: typeof console, methodName: string) {
|
|||
|
||||
emitConsoleChunk(request, methodName, owner, env, stack, args);
|
||||
}
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[incompatible-call]
|
||||
return originalMethod.apply(this, arguments);
|
||||
};
|
||||
if (originalName) {
|
||||
|
|
|
|||
10
yarn.lock
10
yarn.lock
|
|
@ -9108,12 +9108,12 @@ flatted@^3.2.9:
|
|||
resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.3.1.tgz#21db470729a6734d4997002f439cb308987f567a"
|
||||
integrity sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==
|
||||
|
||||
flow-bin@^0.258:
|
||||
version "0.258.1"
|
||||
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.258.1.tgz#5580e6085196800487dae67a71777b572d0c9552"
|
||||
integrity sha512-v08KZw8jiwhA01V59kuCLd628kDJ0ZTX4jguh0P2rboF9rMlGmV8Rd+io1f1U9nWGoORTP2ZUI27X42jFA6eDQ==
|
||||
flow-bin@^0.261:
|
||||
version "0.261.2"
|
||||
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.261.2.tgz#8558c965950f8e38872ea21f66bf04932da2380b"
|
||||
integrity sha512-lTYA05K4obAjyrrX4in3sLZyAECSFCDwQiGpZHJLm8ldCk+qcW11Wcxq/CdvyQAOPR7Kpb5BPRSaj4hwEXIAUw==
|
||||
|
||||
flow-remove-types@^2.258:
|
||||
flow-remove-types@^2.261:
|
||||
version "2.279.0"
|
||||
resolved "https://registry.yarnpkg.com/flow-remove-types/-/flow-remove-types-2.279.0.tgz#3a3388d9158eba0f82c40d80d31d9640b883a3f5"
|
||||
integrity sha512-bPFloMR/A2b/r/sIsf7Ix0LaMicCJNjwhXc4xEEQVzJCIz5u7C7XDaEOXOiqveKlCYK7DcBNn6R01Cbbc9gsYA==
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user