Merge pull request #22182 from damir-sirola/patch-1

Fix react-native FlatList scrollToItem method signature
This commit is contained in:
Eloy Durán
2017-12-14 23:17:25 -05:00
committed by GitHub

View File

@@ -3614,7 +3614,7 @@ export interface FlatListStatic<ItemT> extends React.ComponentClass<FlatListProp
* Requires linear scan through data - use `scrollToIndex` instead if possible.
* May be janky without `getItemLayout` prop.
*/
scrollToItem: (params: { animated?: boolean; index: number; viewPosition?: number }) => void;
scrollToItem: (params: { animated?: boolean; item: ItemT; viewPosition?: number }) => void;
/**
* Scroll to a specific content pixel offset, like a normal `ScrollView`.