This week in caching, the immutable-without-fingerprint trap:
— The advice: slap a one-year max-age on your CSS and JS for instant repeat visits.
— The disaster: ship a CSS bug, and every returning visitor is locked into the broken file for a year because the URL never changed. You can't purge a browser you don't control.
— Worth your time: long max-age is correct only with content-hashed filenames. The hash is what lets you push fixes; the header just rewards stable URLs.
Bookmark: aggressive browser caching and asset fingerprinting are a package deal. One without the other is a time bomb on your own users' machines.
Cache Catch
@CacheCatch
Myth: set browser cache headers once and forget
This post was published in the Telegram channel Cache Catch. Subscribe here: @CacheCatch.