app manifest

This commit is contained in:
TLRZ Seyfferth
2018-01-14 17:31:17 +01:00
parent f45258cebd
commit 65bd645dd9
3 changed files with 85 additions and 0 deletions
+11
View File
@@ -10,6 +10,7 @@
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<!--Import materialize.css-->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-alpha.3/css/materialize.min.css">
<link rel="manifest" href="manifest.json">
</head>
<body>
@@ -169,6 +170,16 @@
<script src="js/vue.js"></script>
<script src="js/model/article.js"></script>
<script src="js/model/inventory_article.js"></script>
<script>
if ('serviceWorker' in navigator) {
navigator.serviceWorker.register('serviceWorker.js')
.then(function(registration) {
console.log("[ServiceWorker] registration successful with scope: ", registration.scope);
}).catch(function(err){
console.error("[ServiceWorker] registration failed: ", err);
})
}
</script>
</body>
</html>