Interactive online courses HTML Academy
2026-03-09 14:11 Diff

Another value of the align-items property is baseline. If you assign it to the container, then the flex items will be aligned along the text baseline in them. This imaginary line runs along the base of the letters.

If you align the flex items along the baseline, they will line up so that the text in them will be set so that it appears to run along a “single line”.

In order to better understand the behavior of the baseline, let’s compare it with another value, flex-start.

Mini Summary. The align-items property controls the alignment of items along the cross axis, and it has five values:

  • The default value stretch,

  • flex-start,

  • flex-end,

  • center,

  • and baseline.