Fix react-native FlatList scrollToItem method signature

This commit is contained in:
Damir
2017-12-14 12:36:30 +01:00
committed by GitHub
parent 22f0a1d2eb
commit 3015b40ec8
+1 -1
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`.