2 ms·
I think you misunderstand the intention of those query keys. They are only meant to be used for cache invalidation, and shouldn't control what content is served
by andix 3y ago
I think you misunderstand the intention of those query keys. They are only meant to be used for cache invalidation, and shouldn't control what content is served.
If you want to serve multiple versions of a static asset at the same time just use different file names.
Edit: That's why SPA frameworks usually use the hash inside the file name approach, so you can keep serving the previous script files for users that didn't reload the application yet.
What we usually do for infrequently updated enterprise applications: we terminate all active sessions during an update and users are forced to do a silent SSO re-login and re-load the SPA. This also allows us to deploy non-backwards compatible API changes without running into problems. This strategy may not fit everywhere though.