html make image fill container code example
Example 1: how to cover full image in css
body {
background-position: center;
background-repeat: no-repeat;
background-size: cover;
}
Example 2: Scaling Images and Videos css
.container {
width: 50%;
height: 200px;
overflow: hidden;
}
.container img {
max-width: 100%;
height: auto;
display: block;
}
Example 3: how to contain image size
overflow: 'hidden',
backgroundSize : 'contain',