Skip to content
NativeScript Unified

NativeScript views

FlexboxLayout

<FlexboxLayout> is a flex container.

AttributeOnValues
flexDirectionFlexboxLayoutrow (default), row-reverse, column, column-reverse
flexWrapFlexboxLayoutnowrap (default), wrap, wrap-reverse
justifyContentFlexboxLayoutflex-start, flex-end, center, space-between, space-around
alignItemsFlexboxLayoutflex-start, flex-end, center, baseline, stretch
alignContentFlexboxLayoutflex-start, flex-end, center, space-between, space-around, stretch
orderchildinteger
flexGrow, flexShrinkchildnumber
alignSelfchildauto, flex-start, flex-end, center, baseline, stretch

The hyphenated forms (flex-direction) are accepted too. Values outside these lists are ignored.

A
B grows
C (order -1)

HTML-first equivalent

The attributes are the CSS flex properties, so they become Tailwind classes: justifyContent="space-between" is justify-between, alignItems="center" is items-center, flexGrow="1" on a child is grow, and order="-1" is -order-1.

A
B grows
C (order -1)