I have been trying to add the CSS code (object-fit: cover) to my site so that the images are “framed” by their div, however, after trying to apply it as a code embed or as a CSS in the site code doesn’t appear to be working. The desired effect that I wish to create is so that the image fills the div so that it can be cropped responsively for mobile like a background image would.
Any suggestions on what I’m doing wrong or why it isn’t working?
The css code I am using for the image (Class: img-fit)
.img-fit { object-fit: cover; width:100%; height:100% }