4 ms·
The quick and dirty solution to this is to have a client response handler that checks for a header set on responses to ensure its a compatible version, then pro
by mdtusz 5y ago
The quick and dirty solution to this is to have a client response handler that checks for a header set on responses to ensure its a compatible version, then prompt a page refresh if not.
- dgb23 5y agoAt this point, I feel like this is the most consistent way. There are notable web apps that do this. There are plenty of good reasons for this, including caching and service workers. It feels dirty because you’re not handling these issues silently. But it’s explicit, clear and it enables a consistent and performant experience.
- bonestormii_ 5y agoI wish more people thought this way about computing.
- cwp 5y agoAn equally-quick but not-at-all-dirty version of this is to use the Accept header and do content negotiation. There is a solution to this exact problem in the HTTP spec.