-
Notifications
You must be signed in to change notification settings - Fork 823
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
New workbox.expiration.Plugin.deleteCacheAndMetadata() method #1500
Conversation
if (localBrowser.getReleaseName() === 'beta') { | ||
await runIntegrationForBrowser(localBrowser); | ||
} | ||
await runIntegrationForBrowser(localBrowser); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was a holdover from when the stable
version of Safari lacked SW support. I took the opportunity to drop that restriction as part of this PR.
PR-Bot Size PluginChanged File SizesNo file sizes have changed. New Files
All File SizesView Table
Workbox Aggregate Size Plugin☠️ WARNING ☠️We are using 170% of our max size budget. Total Size: 24.93KB Gzipped: 9.57KB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
I am still not able to use this method . I am using workbox files from https://storage.googleapis.com/workbox-cdn/releases/3.2.0/workbox-sw.js . On trying to to use this function is throws an error that deleteCacheAndMetadata() is not a method. Can we have a sample code snippet which can help just in case i am doing something wrong |
Sorry, we haven't yet cut a new release of Workbox that includes the changes in this PR. There are a few other open PRs that it would be good to get merged first, and then we'll cut a new release that includes (If you can't wait, you could do a |
Really appreciate such a fast response . By what time are you guys planning to have a new release? |
R: @philipwalton
CC: @josephliccini
Fixes #1365
It took a while to get a hang of what needed to be explicitly
close()
d in order to avoidblocked
errors, but I think this implementation works.I envision making use of this as part of a future PR that will start introducing some opt-in automatic cleanup logic to handle, e.g.,
QUOTA_EXCEEDED
errors. For the time being, though, this is just a standalone method that won't be called anywhere automatically.