Skip to content

Commit 743a8b3

Browse files
committed
update PWA Example
1 parent 5c579a1 commit 743a8b3

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

pwa/registerServiceWorker.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
const CACHE_NAME = "test-cashe-1";
22

33
const urlsToCache = [
4-
'/pwa/',
5-
'/pwa/index.html',
6-
'/pwa/test.css',
7-
'/pwa/test.js'
4+
'/',
5+
'/index.html',
6+
'/test.css',
7+
'/test.js'
88
]
99

1010
self.addEventListener('install', function(event) {
@@ -16,3 +16,7 @@ self.addEventListener('install', function(event) {
1616
})
1717
);
1818
})
19+
20+
self.addEventListener('install', function(event) {
21+
console.log(event.request.url);
22+
})

0 commit comments

Comments
 (0)