There's no better way to learn flex than immediately putting it into action.
Here we have four divs stacked on top of each other, all using a standard display of block
. However, we've decided that we want to move these block divs so that they're side by side instead.
To start, create a class called .flex
, and set it's display property equal to flex
.