Flex renders a React Native View and takes Once UI's layout, spacing, size and surface props, so a screen is built by nesting it instead of writing style objects. Row and Column are Flex with direction preset. Flex is a row by default, as on the web, even though a plain View is a column. See the web Flex page for the full reference.
horizontal and vertical name the axis you see, so they mean the same thing in a row and in a column. center centers on both.
Spacing props take a token such as "16" or "m", or a number of rem, as on the web. Sizes take a token, a number of rem or a percentage. fillWidth stretches to the parent's width, and fit keeps the view at its content's size.
background, border, radius and shadow read the theme's tokens. background also takes "surface", "page", "overlay" and "transparent". A border is 1 point wide unless you set borderWidth.
radius does not clip children. Add overflow="hidden" when it should; on iOS that also hides the view's own shadow.
The breakpoint props xl, l, m, s and xs take an object of props that applies on screens up to that width, as on the web. safeArea adds the screen's safe areas to the padding, once they are passed to ThemeProvider. The overview shows both in detail.
- Bare text. React Native throws on text outside a Text. Flex wraps bare strings and numbers in Text for you, so <Row>Hi</Row> works.
- Position. position takes relative, absolute or static. React Native has no fixed or sticky positioning.
- Left out. solid, single-side borders (borderTop and the rest), the text props (onBackground, align, textVariant and the rest), transition, scrollbar, overflowX and overflowY have no native equivalent.
- dark and light render the view only while the theme is dark or light. They change no colours.
- pointerEvents also takes React Native's "box-none" and "box-only".
- safeArea is native only.
Flex, Row and Column take the same props. They also take the spacing props (padding, paddingX, paddingY, paddingTop and the other sides, the same set for margin, and gap) and every React Native View prop.