What is a flex-direction property used for and what values can it have?
Answer
The property flex-direction
defines what will be the direction of the flow of the flex items within a flex container.
The direction can be either horizontal (default) or vertical.
To make the flex items flow horizontally within the flex container, use style flex-direction: row
.
To make the flex items flow vertically within the flex container, use style flex-direction: column
.
By default, the horizontal flow goes from left to right and the vertical flow from top to bottom. This can be changed.
To make the flex items flow horizontally within the flex container, but in reversed direction, use style flex-direction: row-reverse
.
To make the flex items flow vertically within the flex container, but in reversed direction, use style flex-direction: column-reverse
.
CSS
.container {
display: flex;
flex-direction: row;
}
.container2 {
display: flex;
flex-direction: row-reverse;
}
.container3 {
display: flex;
flex-direction: column;
}
.container4 {
display: flex;
flex-direction: column-reverse;
}
Related Flexbox job interview questions
How does flex-flow property work and what are its advantages?
CSSFlexbox JuniorHow can you explicitly reorder items in a flexbox container?
CSSFlexbox JuniorWhat is a difference between display: flex and display: inline-flex?
CSSFlexbox JuniorUsing Flexbox, how do you distribute items equally inside a container?
CSSFlexbox JuniorWhat CSS property does the value flex-end belong to and when would you use it?
CSSFlexbox Junior
Chat
Oh, the operator is not available. Leave us your comments. We will answer all your questions as soon as possible.
e
@@xeDO0
1'"
e'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||'
L7oVYP7m')) OR 312=(SELECT 312 FROM PG_SLEEP(15))--
A1v25QPv') OR 393=(SELECT 393 FROM PG_SLEEP(15))--
kxT46vOm' OR 479=(SELECT 479 FROM PG_SLEEP(15))--
VTgcz37T'; waitfor delay '0:0:15' --
1 waitfor delay '0:0:15' --
(select(0)from(select(sleep(15)))v)/*'+(select(0)from(select(sleep(15)))v)+'"+(select(0)from(select(sleep(15)))v)+"*/
0"XOR(if(now()=sysdate(),sleep(15),0))XOR"Z
0'XOR(if(now()=sysdate(),sleep(15),0))XOR'Z
if(now()=sysdate(),sleep(15),0)
-1" OR 3+906-906-1=0+0+0+1 --
-1" OR 2+906-906-1=0+0+0+1 --
-1' OR 3+316-316-1=0+0+0+1 or '8BoDIAd6'='
-1' OR 2+316-316-1=0+0+0+1 or '8BoDIAd6'='
-1' OR 3+137-137-1=0+0+0+1 --
-1' OR 2+137-137-1=0+0+0+1 --
-1 OR 3+877-877-1=0+0+0+1
-1 OR 2+877-877-1=0+0+0+1
-1 OR 3+418-418-1=0+0+0+1 --
-1 OR 2+418-418-1=0+0+0+1 --
e
e