HomePhabricator

Limit srcset to widths below the image width

Description

Limit srcset to widths below the image width

Now that we know the width, remove sizes wider than the actual image
width from the srcset, to keep it shorter and avoid requesting the same
file by different names. Also, if the image width (entry added in the
previous commit) is exactly one of the pre-defined widths (for which see
mainly commit 3fce0034de), don’t repeat it, by adding the unique filter.

Details

Provenance
LucasWerkmeisterAuthored on May 15 2022, 4:01 PM
Parents
R2422:f394cb09ef7e: Add full-width URL to srcset
Branches
Unknown
Tags
Unknown
ChangeId
None