My favorite thing about object-fit is that you can use it with img srcset for responsive background images! The picture element is cool if you really need to be serving differently cropped images, but whenever I can get away with same aspect ratio and not supporting IE, I always use object-fit + srcset for all background images.
Definitely a good use case! Did this myself in a recent project in fact.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.