Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
used this technique to expand an image to fill the whole div and maintain aspect ratio
.full-image-div{
width:100%;
height:100%;
object-fit: cover;
overflow: hidden;
}
@dospuntocero

This comment has been minimized.

Copy link
Owner Author

commented Feb 24, 2019

actually, with just height 100% and object-fit will work, but in this case the other stuff was needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.