-
Notifications
You must be signed in to change notification settings - Fork 540
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
[Designer] Update designer service worker #7757
Conversation
Hi @anna-dingler. Thanks for helping make the AdaptiveCards JS renderer + tooling better. As additional verification, once the JS build succeeds, please go to the test site to test out your website/designer changes. |
…o anna/updateDesignerPWA
…o anna/updateDesignerPWA
…/AdaptiveCards into anna/updateDesignerPWA
Hi @anna-dingler. This pull request has had no recent activity for the past 5 days . Please take the necessary actions (review, address feedback or commit if reviewed already) to move this along. |
Staleness reset by anna-dingler |
* Designer: skip waiting when installing service worker * Update caching strategy * Remove designer/ from the precache
Description
When a new service worker is installed, we need to make sure that it claims all existing clients on activation and does not wait to take over for the prior service worker.
Otherwise, the new service worker would not take over until prior clients are closed/refreshed.
See documentation here:
https://developer.mozilla.org/en-US/docs/Web/API/Clients/claim
https://developer.mozilla.org/en-US/docs/Web/API/ServiceWorkerGlobalScope/skipWaiting
The caching strategy was also changed from StaleWhileRevalidate to NetworkFirst.
How Verified
Tested on the Adaptive Cards Designer.
Microsoft Reviewers: Open in CodeFlow