mirror of
https://github.com/MadeBaruna/paimon-moe.git
synced 2025-03-11 18:55:12 +01:00
🚚 Move manifest.json to pwa-manifest.json
This commit is contained in:
parent
2d497a4062
commit
5eefba40cf
3 changed files with 5 additions and 4 deletions
|
@ -3,6 +3,7 @@
|
|||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0" />
|
||||
<title>Paimon.moe</title>
|
||||
<meta name="theme-color" content="#333333" />
|
||||
<meta property="og:title" content="Paimon.moe" />
|
||||
<meta property="og:type" content="website" />
|
||||
|
@ -12,7 +13,7 @@
|
|||
href="https://fonts.googleapis.com/css2?family=Catamaran:wght@600;700;900&family=Poppins:wght@400;500;600&display=swap"
|
||||
rel="stylesheet"
|
||||
/>
|
||||
<link rel="manifest" href="/manifest.json" crossorigin="use-credentials" />
|
||||
<link rel="manifest" href="/pwa-manifest.json" crossorigin="use-credentials" />
|
||||
<link rel="icon" type="image/png" href="/favicon.png" />
|
||||
|
||||
<!-- <script src="https://js.sentry-cdn.com/446c4cef71a54aafb71b698555500b7d.min.js" crossorigin="anonymous"></script> -->
|
||||
|
|
|
@ -41,7 +41,7 @@ self.addEventListener('activate', (event) => {
|
|||
}
|
||||
}
|
||||
|
||||
self.clients.claim();
|
||||
await self.clients.claim();
|
||||
console.log('SW NEED UPDATE', needUpdate);
|
||||
if (needUpdate) {
|
||||
channel.postMessage({
|
||||
|
@ -50,7 +50,7 @@ self.addEventListener('activate', (event) => {
|
|||
});
|
||||
}
|
||||
|
||||
fetchAddCache('/');
|
||||
await fetchAddCache('/');
|
||||
channel.addEventListener('message', (event) => {
|
||||
if (event.data.type === 'fetch-doc') {
|
||||
fetchAddCache(event.data.path);
|
||||
|
@ -74,7 +74,7 @@ self.addEventListener('fetch', async (event) => {
|
|||
}
|
||||
|
||||
const res = await fetch(event.request);
|
||||
if (res.ok) cache.put(event.request, res.clone());
|
||||
if (res.ok) await cache.put(event.request, res.clone());
|
||||
return res;
|
||||
})(),
|
||||
);
|
||||
|
|
Loading…
Add table
Reference in a new issue