Skip to content

Commit

Permalink
fix(cache): only use one service worker file each PWA (#240)
Browse files Browse the repository at this point in the history
  • Loading branch information
hudy9x authored Jul 18, 2024
1 parent 7a5c309 commit 732ad5f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 15 deletions.
13 changes: 0 additions & 13 deletions packages/ui-app/app/_features/ServiceWorker/index.tsx

This file was deleted.

2 changes: 0 additions & 2 deletions packages/ui-app/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import RootLayoutComp from '../layouts/RootLayout'
import { GoalieProvider } from '@goalie/nextjs'

import dynamic from 'next/dynamic'
import RegisterServiceWorker from './_features/ServiceWorker'
const inter = Inter({ subsets: ['latin'] })

const PushNotification = dynamic(
Expand All @@ -34,7 +33,6 @@ export default function RootLayout({
<body className={inter.className}>
<RootLayoutComp>{children}</RootLayoutComp>
<PushNotification />
<RegisterServiceWorker />
</body>
</html>
</GoalieProvider>
Expand Down
1 change: 1 addition & 0 deletions packages/ui-app/public/service-worker.js
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
importScripts("https://js.pusher.com/beams/service-worker.js");
importScripts('sw-cache-resources.js')

0 comments on commit 732ad5f

Please sign in to comment.