Contents
Understanding CSS flex direction
The CSS flex-direction
property allows you to modify item placement in the flex container:
div {
   display: -webkit-flex; /* Safari */
-webkit-flex-direction: column-reverse; /* Safari 6.1 and newer */
display: flex;
flex-direction: column-reverse;
}
Syntax requirements
The syntax for CSS flex-direction
is simple, as you only need to define one out of four available values:
flex-direction: value;
You can see the choice of values in the table below.
- Easy to use with a learn-by-doing approach
- Offers quality content
- Gamified in-browser coding experience
- The price matches the quality
- Suitable for learners ranging from beginner to advanced
- Free certificates of completion
- Focused on data science skills
- Flexible learning timetable
- Simplistic design (no unnecessary information)
- High-quality courses (even the free ones)
- Variety of features
- Nanodegree programs
- Suitable for enterprises
- Paid Certificates of completion
- A wide range of learning programs
- University-level courses
- Easy to navigate
- Verified certificates
- Free learning track available
- University-level courses
- Suitable for enterprises
- Verified certificates of completion
CSS flex-direction property values
Value | Description |
---|---|
row | The default value. Items form a row along the flex container's main axis |
row-reverse | Items form a row along the flex container's main axis, but the direction is reversed |
column | Items form a column along the flex container's block axis |
column-reverse | Items form a column along the flex container's block axis, but the direction is reversed |