diff --git a/index.html b/index.html
index 5aba98f0..f6c36670 100644
--- a/index.html
+++ b/index.html
@@ -4518,6 +4518,17 @@ for (var k = 0; k < b0.split(" AND ").length; k++) {
deferredPrompt.prompt();
});
});
+ if ('serviceWorker' in navigator) { // Register service worker for Chrome PWA
+ window.addEventListener('load', function() {
+ navigator.serviceWorker.register('/sw.js').then(function(registration) {
+ // Registration was successful
+ console.log('ServiceWorker registration successful with scope: ', registration.scope);
+ }, function(err) {
+ // registration failed :(
+ console.log('ServiceWorker registration failed: ', err);
+ });
+ });
+ }
shiftDown = 0;
// If the user presses [ or -, decrease the mouse size by 2
document.addEventListener("keydown", function(e) {
diff --git a/manifest.json b/manifest.json
index ae6bb743..65c22ed4 100644
--- a/manifest.json
+++ b/manifest.json
@@ -23,6 +23,11 @@
"src": "icons/apple-touch-icon.png?v=2",
"sizes": "180x180",
"type": "image/png"
+ },
+ {
+ "src": "icons/apple-touch-icon-144x144.png?v=2",
+ "sizes": "144x144",
+ "type": "image/png"
}
]
}
diff --git a/sw.js b/sw.js
new file mode 100644
index 00000000..8423b382
--- /dev/null
+++ b/sw.js
@@ -0,0 +1 @@
+self.addEventListener('fetch', function(event) {});
\ No newline at end of file