include fonts in service worker
This commit is contained in:
parent
962a4c1faf
commit
ca13436fb4
|
@ -58,7 +58,7 @@ registerRoute(
|
|||
registerRoute(
|
||||
// Add in any other file extensions or routing criteria as needed.
|
||||
({ url }) =>
|
||||
url.origin === self.location.origin && url.pathname.endsWith(".png"),
|
||||
url.origin === self.location.origin && ([".png", ".woff2", "woff"].some(ending => url.pathname.endsWith(ending)))
|
||||
// Customize this strategy as needed, e.g., by changing to CacheFirst.
|
||||
new StaleWhileRevalidate({
|
||||
cacheName: "images",
|
||||
|
|
Loading…
Reference in New Issue