Render inline elements in FlatList in react native

348 Views Asked by At

Hi there i am trying to render some texts beside each other in flatlist, i want to make the text occupy all the available space to the previous row like using display inline in css, i can’t do that in flatlist

I want to render text like in this photo

enter image description here

1

There are 1 best solutions below

3
B. Mohammad On

You can use nested Text components:

<Text> text 1 <Text> text2 </Text> </Text>

I have used this technique with map and its working al hamdolilah:

here the snack example