Interactive online courses HTML Academy
2026-03-09 12:56 Diff

Flexbox uses a property to arrange items along the main axis, justify-content, instead of simply assigning “horizontal” alignment. This property is assigned on the flex container.

Its default value is flex-start. When this value is assigned, the elements are located at the start of the main axis.

In order to arrange the items in the center of the main axis, you need to assign the value center for justify-content.

Let’s place the rugs in the center of the container room.