Elements created with JS are not going on to a new line

Solution 1:

Adding flex-direction: column to the css for your itemsContainer class should put them in a vertical list

.itemsContainer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}