primocms / primo

Primo is a visual CMS with a built-in code editor, Svelte blocks, and static site generator.
https://primocms.org
MIT License
1.92k stars 474 forks source link

Fighting the browser cache in deployed websites #385

Open rallisf1 opened 2 months ago

rallisf1 commented 2 months ago

Is your feature request related to a problem? Please describe. Many browsers (especially chrome mobile) don't respect the caching TTL set by hosts. This leads to changes made in existing symbols to not be visible by guests, even after that TTL, unless they clear their browser history.

Describe the solution you'd like Add the build time timestamp as a file suffix on exported _symbols.

Describe alternatives you've considered I am currently either duplicating symbols, so their id changes, which is not that helpful when being used in many pages; or setting a no-cache, no-store, must-revalidate Cache-Control header on the host.