You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This was working before, with no change in version of workbox packages, so I'm wondering whether this is a change in Google Chrome or its underlying dependencies?
Currently I have some code that clears out a cache when a POST request is successful. It's been working fine until recently, but now when testing it appears to not clear the cache.
This is an excerpt of my code:
...
const searchExpiration = new CacheExpiration("tags-search", {
maxAgeSeconds: 60
});
registerRoute(
({ url, sameOrigin }) => {
return sameOrigin && url.pathname.includes("/api/v1/tags");
},
new NetworkOnly({
plugins: [
{
fetchDidSucceed: async ({ response }) => {
/**
* When we create a new tag, the data in the backend changes and we need
* to invalidate the local cache for the search queries.
*/
console.log('expiring entries for search')
searchExpiration.expireEntries();
...
redacted
...
return response;
}
}
]
}),
"POST"
);
...
I do see expiring entries for search in the console, so the route handler is happy, but the caches are still present in the "tags-search" cache after calling expireEntries().
Google Chrome version: Version 135.0.7049.115 (Official Build) (arm64)
The text was updated successfully, but these errors were encountered:
Hi there! Thanks for the great library!
This was working before, with no change in version of
workbox
packages, so I'm wondering whether this is a change in Google Chrome or its underlying dependencies?Currently I have some code that clears out a cache when a
POST
request is successful. It's been working fine until recently, but now when testing it appears to not clear the cache.This is an excerpt of my code:
I do see
expiring entries for search
in the console, so the route handler is happy, but the caches are still present in the"tags-search"
cache after callingexpireEntries()
.Google Chrome version:
Version 135.0.7049.115 (Official Build) (arm64)
The text was updated successfully, but these errors were encountered: