Though I have solved this easily using bootstrap, I wish to get used to the flex-box model and html 5. I have 3 images to display in just one row (no wrapping) with space in between the images. Below is my html:
<article>
<figure>
<picture>
<img src="images_srcset/desert-dolphin-medium.jpg" alt="Dolphin art">
</picture>
<figcaption>DESERT-BOTTLE-DOLPHIN</figcaption>
</figure>
<figure>
<picture>
<img src="images_srcset/abc-dolphin-medium.jpg" alt="a-b-c-dolphin">
</picture>
<figcaption>A-B-C-DOLPHIN</figcaption>
</figure>
<figure>
<picture>
<img src="images_srcset/delfin-bananas-medium.jpg" alt="Banana art">
</picture>
<figcaption>BANANA-DELPHIN</figcaption>
</figure>
</article>
I have used all the methods I read under the question "Better way to set distance between flexbox items". None worked for the above. My last tried css is:
article {
width: 100vw;
display: flex;
flex-direction: row;
flex-wrap: wrap;
justify-content: space-between;
}
article > figure {
box-sizing: border-box;
display: flex;
flex-direction: row;
flex-wrap: wrap;
width: 32vw;
margin-right: 1.333vw;
}
Please what am I doing wrong?