Cache‑Control header limits for Astro <Image> component across adapters
0 reputation · 01 Nov 2022, 18:53 UTC
The goal is to determine whether the Astro component should automatically include a sensible Cache‑Control header for optimized images to provide consistent caching behavior without requiring adapter‑specific configuration.
Currently the component does not inject any header by default, and while the Node adapter allows manual middleware to set headers, the Vercel and Netlify adapters rely on their edge caches, leading to inconsistent behavior across platforms.
Should the component emit a default Cache‑Control header? If so, what value (e.g., stale‑while‑revalidate) would be appropriate? How would this default interact with existing adapter‑specific middleware or edge cache settings?