improve Cache-Control for static content
Currently we have Cache-Control
set to public no-cache
, which makes browsers always ask the server if the content has changed since last time they fetched it before serving the cached copy. This makes sense for something like api responses, which may change at any point in time, but is in my opinion unnecessary for something that changes very rarely like emoji images and the frontend bundle. I think we should set Cache-Control
to something like public max-age=86400 must-revalidate
(cache for a maximum of one day and then ask the server if the content has changed)
@feld what are your thoughts?