You have two possibilities.
You can set flex-direction
to column
. This will set a vertical main-axis, laying out your items vertically.
You can also set flex-wrap
to wrap
. This tells your flex container that it's OK to wrap elements when they would exceed their parent's width. In your case, it would wrap your second element to the next "row."
If your items are the same width as their parent container as in your example, both methods will work the same way. If the items have a different width than their parent (or, really, in any other case where you'll want elements side-by-side in a grid like the case you mention in your comment), you'll want to use flex-wrap
so things layout correctly side-by-side before wrapping to another row.