Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to use flatlist keyextractor

<FlatList 
  data={[{name: 'a'}, {name: 'b'}]} 
  renderItem={
    ({item}) => <Text>{item.name}</Text>
  } 
  keyExtractor={(item, index) => index.toString()}
/>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #flatlist #keyextractor
ADD COMMENT
Topic
Name
1+5 =