Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for a unique id when caching the site's manifest. #71

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

barbhackk
Copy link

Hi,

When used with a PWA which generates different content for each page (for example a profile page with a firstname, a lastname and an avatar and therefore different icons and splash screens) it happens that between several tabs open at the same time, the icons generated are identical at first (as long as you don't close the tabs - grants the documentation).

Indeed, the manifest file as well as the icons are stored with an identifier __pwacompat_manifest or __pwacompat_ios

To avoid this, I added support for a unique ID for each key.

If you need to display a PWA whose icons are dynamic, please enter a meta pwacompat-manifest-id tag with a unique identifier like uuid for exemple.

<meta name="pwacompat-manifest-id" content="1124d9e8-6266-4bcf-8035-37a02ba75c69" />

Otherwise you will always have the same information between all tabs even if the content is different.
Thus the key in session will be personalized with the identifier.

Thanks ☺️,

Sebastien

Copy link

google-cla bot commented Dec 1, 2023

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant