diff --git a/packages/react-native/Libraries/WebPerformance/Performance.js b/packages/react-native/Libraries/WebPerformance/Performance.js index a6e9d066804..e8c4c492cfd 100644 --- a/packages/react-native/Libraries/WebPerformance/Performance.js +++ b/packages/react-native/Libraries/WebPerformance/Performance.js @@ -141,7 +141,7 @@ export default class Performance { } // Startup metrics is not used in web, but only in React Native. - get reactNativeStartupTiming(): ReactNativeStartupTiming { + get rnStartupTiming(): ReactNativeStartupTiming { if (NativePerformance?.getReactNativeStartupTiming) { const { startTime, diff --git a/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap b/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap index 32f662953d2..29d3b8f5cc7 100644 --- a/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap +++ b/packages/react-native/Libraries/__tests__/__snapshots__/public-api-test.js.snap @@ -8976,7 +8976,7 @@ declare export class PerformanceMeasure extends PerformanceEntry { declare export default class Performance { eventCounts: EventCounts; get memory(): MemoryInfo; - get reactNativeStartupTiming(): ReactNativeStartupTiming; + get rnStartupTiming(): ReactNativeStartupTiming; mark(markName: string, markOptions?: PerformanceMarkOptions): PerformanceMark; clearMarks(markName?: string): void; measure( diff --git a/packages/rn-tester/js/examples/Performance/PerformanceApiExample.js b/packages/rn-tester/js/examples/Performance/PerformanceApiExample.js index 6c4e31726a0..427d6058640 100644 --- a/packages/rn-tester/js/examples/Performance/PerformanceApiExample.js +++ b/packages/rn-tester/js/examples/Performance/PerformanceApiExample.js @@ -27,8 +27,6 @@ function MemoryExample(): React.Node { const onGetMemoryInfo = useCallback(() => { // performance.memory is not included in bom.js yet. // Once we release the change in flow this can be removed. - // $FlowFixMe[prop-missing] - // $FlowFixMe[incompatible-call] setMemoryInfo(performance.memory); }, []); return ( @@ -58,9 +56,7 @@ function StartupTimingExample(): React.Node { const onGetStartupTiming = useCallback(() => { // performance.reactNativeStartupTiming is not included in bom.js yet. // Once we release the change in flow this can be removed. - // $FlowFixMe[prop-missing] - // $FlowFixMe[incompatible-call] - setStartUpTiming(performance.reactNativeStartupTiming); + setStartUpTiming(performance.rnStartupTiming); }, []); return (