Skip to content

Commit

Permalink
rename service-worker.js —> sw.js
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeed committed Oct 31, 2017
1 parent c7cb759 commit 2866f5f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion config/setup.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module.exports = isProd => {
new ExtractText('styles.[hash].css'),
new SWPrecache({
minify: true,
filename: 'service-worker.js',
filename: 'sw.js',
dontCacheBustUrlsMatching: /./,
navigateFallback: 'index.html',
staticFileGlobsIgnorePatterns: [/\.map$/]
Expand Down
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ init();
if (process.env.NODE_ENV === 'production') {
// cache all assets if browser supports serviceworker
if ('serviceWorker' in navigator && location.protocol === 'https:') {
navigator.serviceWorker.register('/service-worker.js');
navigator.serviceWorker.register('/sw.js');
}

// add Google Analytics
Expand Down

0 comments on commit 2866f5f

Please sign in to comment.