CSS Flexbox Flashcards

1
Q

What is Flexbox

A

One-dimensional layout method for laying out items in rows or columns.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why use Flexbox?

A

Allows us to distribute space dynamically across elements of an unknown size.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How do you turn on flexbox property?

A

display: flex;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is main axis in flexbox?

A

By default main axis = x (horizontal left to right but can change)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is cross axis?

A

By default cross axis = y(vertical top to bottom but can change)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Define Flex direction

A

Allows us to decide the direction of main axis in container.

flex-direction: row; (default)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How do you go right to left in direction?

A

flex-direction: row-reverse;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How do you go up to down in direction?

A

flex-direction: column;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How do you go down to up in direction?

A

flex-direciton: column-reverse;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Define justify content

A

Justify content determines how the actual elements/content is distributed across the main axis. Dependent on how the flex direction is configured.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are the values for the property justify-content:

A
justify-content: flex-start; **default
justify-content: flex-end;
justify-content: center;
justify-content: space-between;
justify-content: space-around;
justify-content: space-evenly;
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Define Flex Wrap

A

Determines whether elements are going to wrap along main. And dictates the direction of the cross axis.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are the values of flex-wrap:

A

flex-wrap: wrap;
flex-wrap: wrap-reverse;
flex-wrap: nowrap;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Define align items.

A

Distributes space/items along the cross axis.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are the values of align-items:

A

align-items: flex-start; **default
align-items: flex-end;
align-items: center;
align-items: baseline;

How well did you know this?
1
Not at all
2
3
4
5
Perfectly