Flexbox in React Native
React Native lays out every View with flexbox, using CSS property names but different defaults: flexDirection is column, flexShrink is 0, and every View is already a flex container. flex: 1 means take the remaining space.
Minimal example
<View style={{ flexDirection: "row", alignItems: "center", gap: 12 }}>
<Image source={{ uri }} style={{ width: 72, height: 72 }} />
<Text style={{ flex: 1 }} numberOfLines={1}>{name}</Text>
</View>Learn this concept
Lesson 4.1 · React Native screen layoutPrerequisite conceptsCore components
RelatedStyleSheet