Containers
.flex-container {
display: flex; /* or flex-inline*/
}
Container
Direction
{
flex-direction: row | row-reverse | column | column-reverse;
}
row (default)
1
2
3
4
row-reverse
1
2
3
4
column
1
2
3
4
column-reverse
1
2
3
4
Wrap
{
flex-wrap: nowrap | wrap | wrap-reverse;
}
1
2
3
4
5
6
7
8
1
2
3
4
5
6
7
8
1
2
3
4
5
6
7
8
Flex-Flow
This is a shorthand for the flex-direction and flex-wrap properties, which together define the flex container’s main and cross axes. The default value is row nowrap.
.container {
flex-flow: column wrap;
}
Justify Content
.container {
justify-content: flex-start | flex-end | center | space-between | space-around | space-evenly | start | end | left | right ... + safe | unsafe;
}
The safest values are flex-start, flex-end, and center.
1
2
3
4
1
2
3
4
1
2
3
4