Learn how to create an Image Grid.
Read on how to do it in this link: https://www.w3schools.com/howto/howto_js_image_grid.asp
Image Grid
Learn how to create an image gallery that varies between four, two or full-width images with a click of a button:
Try it yourself here: https://www.w3schools.com/howto/tryit.asp?filename=tryhow_js_image_grid