From e31ff4212b62e4b7dc3ed746d790645e893fbd11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dawid=20Ma=C5=82ecki?= Date: Wed, 22 Jan 2025 10:34:21 -0800 Subject: [PATCH] Added type for _captureRef in SectionList (#48863) Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/48863 Changelog: [General][Changed] - Added explicit type for argument in _captureRef in SectionList Reviewed By: huntie Differential Revision: D68493326 fbshipit-source-id: 906a13b13e9fc7ee2c61a8d5c7caa72c0656440f --- packages/react-native/Libraries/Lists/SectionList.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/react-native/Libraries/Lists/SectionList.js b/packages/react-native/Libraries/Lists/SectionList.js index 7461f1e1b3c..77b9566ec50 100644 --- a/packages/react-native/Libraries/Lists/SectionList.js +++ b/packages/react-native/Libraries/Lists/SectionList.js @@ -261,9 +261,7 @@ export default class SectionList< } _wrapperListRef: ?React.ElementRef; - /* $FlowFixMe[missing-local-annot] The type annotation(s) required by Flow's - * LTI update could not be added via codemod */ - _captureRef = ref => { + _captureRef = (ref: ?React.RefOf) => { this._wrapperListRef = ref; }; }