Note from 12 October 2022

How do you deal with images that need to have a fluid width but fixed height?

I tend to start from the lowest width/height ratio and increase, knowing larger images will have hidden parts above and below… 😔

Anything better?

  1. Note from 4 April 2024

    Most mentions of the magical CSS object-fit: cover; in development tutorials should be accompanied by a warning: in most situations, it means the browser will download an image that is larger than required (at least in one direction), and optimization on the server side could be a better option.