I am trying to display this data in a FlatList.
Array [
Object {
"-N1gqvHXUi2LLGdtIumv": Object {
"Message": "Aeaaeaea",
"Message_CreatedAt": 1652167522975,
"Message_by_Email": "[email protected]",
"Message_by_ID": "DgGfooQIMQQ1rs5xlmmSKCSTrKA2",
},
"-N1hB3A_Q7-K75UbvPSM": Object {
"Message": "Yyoo",
"Message_CreatedAt": 1652173063182,
"Message_by_Email": "[email protected]",
"Message_by_ID": "DgGfooQIMQQ1rs5xlmmSKCSTrKA2",
},
},
]
My data looks like this, its multiple objects in a single object within an array, and each object has multiple unique Ids how can I read the data.
My FlatList code
<FlatList data={data} renderItem={(Item) => <Text>{Item.item. Message}</Text>}
Here the problem is, FlatList is considering the main object and not the children, how can I access and render the children in a Flatlist and how can I access the unique Id.