When migrating from ListView to Flatlist I am getting values in an object I need to get as a value in array. 

I have modified the react-native-modal-filter-picker to a custom component which needs to work for me. Here onSelect shows the results in object. 

```
renderOptionList = () => {
   const {
     noResultsText,
     listViewProps,
     keyboardShouldPersistTaps,
     keyExtractor,
   } = this.props

   const { ds } = this.state;
   if (!ds.length) {
     return (
     <FlatList
       data={ds}
         keyExtractor={keyExtractor||this.keyExtractor}
         {...listViewProps}
         renderItem={() => (
           <View style={styles.noResults}>
             <Text style={styles.noResultsText}>{noResultsText}</Text>
           </View>
         )}
       />
     )
   } else {
     return (
       <FlatList
         keyExtractor={keyExtractor||this.keyExtractor}
         {...listViewProps}
         data={ds}
         renderItem={this.renderOption}
       />
     )
   }
 };

 renderOption = ({item}) => {
   const {
     selectedOption,
     renderOption,
     optionTextStyle,
     selectedOptionTextStyle
   } = this.props;

   const { key, label } = item
   let style = styles.optionStyle;
   let textStyle = optionTextStyle||styles.optionTextStyle;
   if (key === selectedOption) {
     style = styles.selectedOptionStyle;
     textStyle = selectedOptionTextStyle ||styles.selectedOptionTextStyle
   }

   if (renderOption) {
     return renderOption(item, key === selectedOption)
   } else {
     return (
       <TouchableOpacity activeOpacity={0.7}
         style={style}
         onPress={() => this.props.onSelect(item)}
       >
         <Text style={textStyle}>{label}</Text>
       </TouchableOpacity>
     )
   }
 };

```