Skip to content

Commit

Permalink
fix: type definition
Browse files Browse the repository at this point in the history
  • Loading branch information
BANG88 committed Dec 14, 2018
1 parent 8638f6e commit 4e4973b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion components/list-view/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export interface ListViewProps<T> extends UltimateListViewProps {
},
) => React.ReactElement<any> | null;
numColumns?: number;
keyExtractor: (item: T, index: number) => string;
keyExtractor?: (item: T, index: number) => string;
}
export interface ListViewState {}
class ListView<T> extends React.PureComponent<ListViewProps<T>, ListViewState> {
Expand Down Expand Up @@ -93,6 +93,7 @@ class ListView<T> extends React.PureComponent<ListViewProps<T>, ListViewState> {
return (
<UltimateListView
key="ant-list-view"
keyExtractor={(_: any, index: number) => `item-${index}`} // this is required when you are using FlatList
refreshableMode={Platform.OS === 'ios' ? 'advanced' : 'basic'}
numColumns={1}
waitingSpinnerText={locale.loading}
Expand Down

0 comments on commit 4e4973b

Please sign in to comment.