Technical notes on web development, DevOps, and AI integration.
1 article
A CSS max-width clamp ships, but the vw sizes hint keeps promising a bigger slot. Make the contract honest with pixel values so srcset picks right.
TL;DR: Clamping an oversized hero image with CSS max-width looks fixed visually, but the browser still downloads a huge file. The culprit was a stale sizes attribute promising 40vw, so the browser picked a 576px srcset candidate for a 330px box. Honest pixel values in sizes, matched to the breakpoint clamp, keep downloads lean.