Skip to content

Commit

Permalink
chore: fix types on ContactList example
Browse files Browse the repository at this point in the history
  • Loading branch information
gorhom committed Dec 22, 2020
1 parent 4af7d5c commit ebfad4c
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions example/src/components/contactList/ContactList.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
import React, { useMemo, useCallback } from 'react';
import { StyleSheet, Text, Platform, View, ViewStyle } from 'react-native';
import {
StyleSheet,
Text,
Platform,
View,
ViewStyle,
StyleProp,
} from 'react-native';
import { useSafeAreaInsets } from 'react-native-safe-area-context';
import { useFocusEffect } from '@react-navigation/native';
import {
Expand All @@ -17,7 +24,7 @@ import ContactItem from '../contactItem';
export interface ContactListProps {
type: 'FlatList' | 'SectionList' | 'ScrollView' | 'View';
count?: number;
style?: ViewStyle;
style?: StyleProp<ViewStyle>;
header?: (() => JSX.Element) | null;
onItemPress?: () => void;
}
Expand All @@ -43,6 +50,7 @@ const ContactList = ({
const contentContainerStyle = useMemo(
() => ({
...styles.contentContainer,
// @ts-ignore
...style,
paddingBottom: bottomSafeArea,
}),
Expand Down

0 comments on commit ebfad4c

Please sign in to comment.