diff --git a/packages/react-native/Libraries/Utilities/PolyfillFunctions.js b/packages/react-native/Libraries/Utilities/PolyfillFunctions.js index 5731a3f4c49f..4904cca0fbfb 100644 --- a/packages/react-native/Libraries/Utilities/PolyfillFunctions.js +++ b/packages/react-native/Libraries/Utilities/PolyfillFunctions.js @@ -30,7 +30,7 @@ export function polyfillObjectProperty( name: string, getValue: () => T, ): void { - const descriptor = Object.getOwnPropertyDescriptor<$FlowFixMe>(object, name); + const descriptor = Object.getOwnPropertyDescriptor(object, name); if (__DEV__ && descriptor) { const backupName = `original${name[0].toUpperCase()}${name.slice(1)}`; Object.defineProperty(object, backupName, descriptor); diff --git a/packages/react-native/src/private/webapis/dom/oldstylecollections/HTMLCollection.js b/packages/react-native/src/private/webapis/dom/oldstylecollections/HTMLCollection.js index 4295da55838d..a3b3d0ec215e 100644 --- a/packages/react-native/src/private/webapis/dom/oldstylecollections/HTMLCollection.js +++ b/packages/react-native/src/private/webapis/dom/oldstylecollections/HTMLCollection.js @@ -18,7 +18,7 @@ import {setPlatformObject} from '../../webidl/PlatformObjects'; // IMPORTANT: The type definition for this module is defined in `HTMLCollection.js.flow` // because Flow only supports indexers in classes in declaration files. -const REUSABLE_PROPERTY_DESCRIPTOR: {...PropertyDescriptor, ...} = { +const REUSABLE_PROPERTY_DESCRIPTOR: {...PropertyDescriptor, ...} = { value: {}, enumerable: true, configurable: false, diff --git a/packages/react-native/src/private/webapis/dom/oldstylecollections/NodeList.js b/packages/react-native/src/private/webapis/dom/oldstylecollections/NodeList.js index 31eee8b52ad7..7a54461eda9d 100644 --- a/packages/react-native/src/private/webapis/dom/oldstylecollections/NodeList.js +++ b/packages/react-native/src/private/webapis/dom/oldstylecollections/NodeList.js @@ -22,7 +22,7 @@ import {setPlatformObject} from '../../webidl/PlatformObjects'; // IMPORTANT: The Flow type definition for this module is defined in `NodeList.js.flow` // because Flow only supports indexers in classes in declaration files. -const REUSABLE_PROPERTY_DESCRIPTOR: {...PropertyDescriptor, ...} = { +const REUSABLE_PROPERTY_DESCRIPTOR: {...PropertyDescriptor, ...} = { value: {}, writable: false, };