Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Commit

Permalink
Cache the polyfills in runtimeCaching
Browse files Browse the repository at this point in the history
  • Loading branch information
abdonrd authored Sep 29, 2017
1 parent b8d74a5 commit 6731b6b
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion sw-precache-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,18 @@ module.exports = {
staticFileGlobs: [
'index.html',
'manifest.json',
'bower_components/webcomponentsjs/*',
'bower_components/webcomponentsjs/webcomponents-loader.js',
],
runtimeCaching: [
{
urlPattern: /bower_components\/webcomponentsjs\/.*.js/,
handler: 'fastest',
options: {
cache: {
name: 'webcomponentsjs-polyfills-cache'
}
}
}
],
navigateFallback: 'index.html',
};

0 comments on commit 6731b6b

Please sign in to comment.