diff --git a/.flowconfig b/.flowconfig index 379f7bddca1..f66886c76f1 100644 --- a/.flowconfig +++ b/.flowconfig @@ -76,4 +76,4 @@ untyped-import untyped-type-import [version] -^0.200.0 +^0.201.0 diff --git a/.flowconfig.android b/.flowconfig.android index 7921426e1d7..fcdd27ceeab 100644 --- a/.flowconfig.android +++ b/.flowconfig.android @@ -76,4 +76,4 @@ untyped-import untyped-type-import [version] -^0.200.0 +^0.201.0 diff --git a/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js b/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js index 268b7c032fa..d3a722dea6f 100644 --- a/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js +++ b/Libraries/Components/DrawerAndroid/DrawerLayoutAndroid.android.js @@ -238,6 +238,7 @@ class DrawerLayoutAndroid extends React.Component { * LTI update could not be added via codemod */ _onDrawerSlide = event => { if (this.props.onDrawerSlide) { + // $FlowFixMe[unused-promise] this.props.onDrawerSlide(event); } if (this.props.keyboardDismissMode === 'on-drag') { diff --git a/Libraries/Components/Keyboard/KeyboardAvoidingView.js b/Libraries/Components/Keyboard/KeyboardAvoidingView.js index 2f48f9e677a..9fb5637c6c5 100644 --- a/Libraries/Components/Keyboard/KeyboardAvoidingView.js +++ b/Libraries/Components/Keyboard/KeyboardAvoidingView.js @@ -107,6 +107,7 @@ class KeyboardAvoidingView extends React.Component { _onKeyboardChange = (event: ?KeyboardEvent) => { this._keyboardEvent = event; + // $FlowFixMe[unused-promise] this._updateBottomIfNecessary(); }; diff --git a/Libraries/Components/RefreshControl/RefreshControl.js b/Libraries/Components/RefreshControl/RefreshControl.js index e40344ec969..0fb4860582f 100644 --- a/Libraries/Components/RefreshControl/RefreshControl.js +++ b/Libraries/Components/RefreshControl/RefreshControl.js @@ -183,6 +183,7 @@ class RefreshControl extends React.Component { _onRefresh = () => { this._lastNativeRefreshing = true; + // $FlowFixMe[unused-promise] this.props.onRefresh && this.props.onRefresh(); // The native component will start refreshing so force an update to diff --git a/Libraries/Components/Switch/Switch.js b/Libraries/Components/Switch/Switch.js index 7197ded8b1e..af27bd58ada 100644 --- a/Libraries/Components/Switch/Switch.js +++ b/Libraries/Components/Switch/Switch.js @@ -160,7 +160,9 @@ const SwitchWithForwardedRef: React.AbstractComponent< const [native, setNative] = React.useState({value: (null: ?boolean)}); const handleChange = (event: SwitchChangeEvent) => { + // $FlowFixMe[unused-promise] onChange?.(event); + // $FlowFixMe[unused-promise] onValueChange?.(event.nativeEvent.value); setNative({value: event.nativeEvent.value}); }; diff --git a/Libraries/Core/Devtools/openFileInEditor.js b/Libraries/Core/Devtools/openFileInEditor.js index c9eb343031e..4dd8dc08ca5 100644 --- a/Libraries/Core/Devtools/openFileInEditor.js +++ b/Libraries/Core/Devtools/openFileInEditor.js @@ -13,6 +13,7 @@ const getDevServer = require('./getDevServer'); function openFileInEditor(file: string, lineNumber: number) { + // $FlowFixMe[unused-promise] fetch(getDevServer().url + 'open-stack-frame', { method: 'POST', headers: { diff --git a/Libraries/Core/Devtools/openURLInBrowser.js b/Libraries/Core/Devtools/openURLInBrowser.js index 986fa5d1f3f..66f8ccbce52 100644 --- a/Libraries/Core/Devtools/openURLInBrowser.js +++ b/Libraries/Core/Devtools/openURLInBrowser.js @@ -13,6 +13,7 @@ const getDevServer = require('./getDevServer'); function openURLInBrowser(url: string) { + // $FlowFixMe[unused-promise] fetch(getDevServer().url + 'open-url', { method: 'POST', body: JSON.stringify({url}), diff --git a/Libraries/LogBox/UI/LogBoxMessage.js b/Libraries/LogBox/UI/LogBoxMessage.js index 772c6680103..38f4e0436b2 100644 --- a/Libraries/LogBox/UI/LogBoxMessage.js +++ b/Libraries/LogBox/UI/LogBoxMessage.js @@ -76,6 +76,7 @@ function TappableLinks(props: { fragments.push( { + // $FlowFixMe[unused-promise] Linking.openURL(link); }} key={++indexCounter} diff --git a/Libraries/ReactNative/AppRegistry.js b/Libraries/ReactNative/AppRegistry.js index d38745e54bf..af3fa3aaf5c 100644 --- a/Libraries/ReactNative/AppRegistry.js +++ b/Libraries/ReactNative/AppRegistry.js @@ -312,6 +312,7 @@ const AppRegistry = { NativeHeadlessJsTaskSupport && reason instanceof HeadlessJsTaskError ) { + // $FlowFixMe[unused-promise] NativeHeadlessJsTaskSupport.notifyTaskRetry(taskId).then( retryPosted => { if (!retryPosted) { diff --git a/package.json b/package.json index 39fae1fedf4..7234473515e 100644 --- a/package.json +++ b/package.json @@ -152,7 +152,7 @@ "yargs": "^17.6.2" }, "devDependencies": { - "flow-bin": "^0.200.0", + "flow-bin": "^0.201.0", "hermes-eslint": "0.8.0", "mock-fs": "^5.1.4", "react": "18.2.0", diff --git a/packages/hermes-inspector-msggen/src/index.js b/packages/hermes-inspector-msggen/src/index.js index 5826643c753..f44d57300c9 100644 --- a/packages/hermes-inspector-msggen/src/index.js +++ b/packages/hermes-inspector-msggen/src/index.js @@ -248,4 +248,5 @@ async function main(): Promise { iw.write(); } +// $FlowFixMe[unused-promise] main(); diff --git a/repo-config/package.json b/repo-config/package.json index e5796c5a92f..656c7a09a72 100644 --- a/repo-config/package.json +++ b/repo-config/package.json @@ -38,7 +38,7 @@ "eslint-plugin-react-hooks": "^4.6.0", "eslint-plugin-react-native": "^4.0.0", "eslint-plugin-relay": "^1.8.3", - "flow-bin": "^0.200.0", + "flow-bin": "^0.201.0", "inquirer": "^7.1.0", "jest": "^29.2.1", "jest-junit": "^10.0.0", diff --git a/yarn.lock b/yarn.lock index 9e2944f35f2..b5862b0f954 100644 --- a/yarn.lock +++ b/yarn.lock @@ -4550,10 +4550,10 @@ flatted@^3.1.0: resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.2.tgz#64bfed5cb68fe3ca78b3eb214ad97b63bedce561" integrity sha512-JaTY/wtrcSyvXJl4IMFHPKyFur1sE9AUqc0QnhOaJ0CxHtAoIV8pYDzeEfAaNEtGkOfq4gr3LBFmdXW5mOQFnA== -flow-bin@^0.200.0: - version "0.200.0" - resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.200.0.tgz#bae10e7454aca131f72f084f64371f5098c5be07" - integrity sha512-4KquALYPkCCTCZ43GIqTDZDOf4znU3/kXsigpiwwORV8l/ctqwvKkqCOhjqvGy5DtbiL6WTPBqLwGAlxeGeNIA== +flow-bin@^0.201.0: + version "0.201.0" + resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.201.0.tgz#bc8d7c3687526313d7a24dd920873a0273148d81" + integrity sha512-fqx6CMOhX9Xm4mN+tq/c7sqcm8aHFV1ipbLz2ZCzoNcPuUNZPoSVYm4p0qZqH0HyzMMEP1OWlU7dIkuSJ02cpg== flow-enums-runtime@^0.0.5: version "0.0.5"