diff --git a/packages/metro-config/src/index.flow.js b/packages/metro-config/src/index.flow.js index ee75437090..2b4c708b4c 100644 --- a/packages/metro-config/src/index.flow.js +++ b/packages/metro-config/src/index.flow.js @@ -58,7 +58,6 @@ export function getDefaultConfig(projectRoot: string): ConfigT { getModulesRunBeforeMainModule: () => [ require.resolve('react-native/Libraries/Core/InitializeCore'), ], - // $FlowFixMe[untyped-import] getPolyfills: () => require('@react-native/js-polyfills')(), isThirdPartyModule({path: modulePath}: $ReadOnly<{path: string, ...}>) { return ( diff --git a/packages/polyfills/index.js b/packages/polyfills/index.js index 90aa1dc083..ce52e3cab9 100644 --- a/packages/polyfills/index.js +++ b/packages/polyfills/index.js @@ -4,12 +4,13 @@ * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * + * @flow strict-local * @format */ 'use strict'; -module.exports = () => [ +module.exports = () /*: Array */ => [ require.resolve('./console.js'), require.resolve('./error-guard.js'), ]; diff --git a/packages/react-native/rn-get-polyfills.js b/packages/react-native/rn-get-polyfills.js index c051fd4213..bf0d0428de 100644 --- a/packages/react-native/rn-get-polyfills.js +++ b/packages/react-native/rn-get-polyfills.js @@ -4,6 +4,7 @@ * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * + * @flow strict-local * @format */