lundi 31 octobre 2016

Can I safely rev my Web App Manifest URL?

Static asset revisioning tools like the Rails Asset Pipeline, Laravel Elixir, or gulp-rev and gulp-rev-all put file hashes into URLs as a cache-busting strategy. Whenever the content of a file changes, it gets assigned a new URL the next time the website's static assets are compiled (changing from e.g. example.b5178d.jpg to example.aa349e.jpg) and references to it in other static assets rewritten to point to the new file.

Is it safe to use this strategy for a Web App Manifest (spec, MDN), or should the manifest for a given app always live at the same URL? I'm frightened that browsers or other software that uses the Web App Manifest might treat its URL as a unique identifier. One can imagine this causing bugs if the URL is in fact constantly changing due to static asset revisioning; for instance, a phone OS might fail to recognise that an app has already been added to the home screen because its manifest URL has changed.

Does the spec offer any guidance on whether changing the URL of a Web App Manifest is safe? And whatever the spec says, what is the current reality?




Aucun commentaire:

Enregistrer un commentaire