css to get image to inside div to always fill code example
Example 1: how to contain image size
overflow: 'hidden',
backgroundSize : 'contain',
Example 2: make image stretch to fit div
Just apply without any changing any code
img {
width: 100%;
}