Initial Push
This commit is contained in:
1 parent
00e89ffd84
commit
a6761d172e
14 files changed
+2187
-2
No files matched your search
@@ -0,0 +1,23 @@
|
||||
const cache_identifier = "scoicide-squad-cache-version-1";
|
||||
|
||||
self.addEventListener("install", function(installation_event) {
|
||||
installation_event.waitUntil(
|
||||
caches.open(cache_identifier).then(function(cache_object) {
|
||||
return cache_object.addAll([
|
||||
"/",
|
||||
"/static/stylesheet.css",
|
||||
"/static/behavior.js",
|
||||
"/static/logo.svg",
|
||||
"/static/manifest.json"
|
||||
]);
|
||||
})
|
||||
);
|
||||
});
|
||||
|
||||
self.addEventListener("fetch", function(network_fetch_event) {
|
||||
network_fetch_event.respondWith(
|
||||
caches.match(network_fetch_event.request).then(function(cached_response) {
|
||||
return cached_response || fetch(network_fetch_event.request);
|
||||
})
|
||||
);
|
||||
});
|
||||
Reference in new issue
Block a user