Responsive Image in Bootstrap 4

2019-08-10


We might remember we used to use the code below for responsive image in Bootstrap 3:

<img src="myImage.jpg" class="img-responsive" alt="...">

But in Bootstrap 4 the img-responsive is changed to .img-fluid

<img src="myImage.jpg" class="img-fluid" alt="...">

Also, in Bootstrap4:

.img-rounded is named as .rounded

.img-circle is named as .rounded-circle

We can read more changes in Bootstrap 4 from here (Migrating to v4).