I am working on a 4 column layout with image thumbnails.
https://i.sstatic.net/ZNaNg.png
Here is the code snippet:
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
<title>KTM Cart</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
<meta content='width=device-width, initial-scale=1' name='viewport'>
</head>
<body>
<div class='container-fluid'>
<div class='row'>
<div class='col-md-3 col-sm-6 col-6 mb-4'>
...
...
... more HTML code here ...
<div class='row'>
<div class='col-md-3 col-sm-6 col-6 mb-4'>
...
...
</div>
</body>
</html>
The issue I am facing is that the images in the layout initially appear collapsed and cause a jumping effect when they finish loading. How can I display an empty box of fixed size before the image finishes downloading to prevent this content jumping? I have tried wrapping the image in a div tag with fixed height and width but it did not work. Any suggestions or help would be greatly appreciated. Thank you!
UPDATE:
You can see a similar technique used on the BBC website where the images are displayed in fixed-size boxes to prevent content jumping.