Skip to content

Commit

Permalink
disabled pwa for now
Browse files Browse the repository at this point in the history
  • Loading branch information
Yash-Ainapure committed Nov 11, 2024
1 parent ad105ce commit 5269f81
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions backend/src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ const app = express();
const allowedOrigins = [
"http://localhost:5173",
"https://dypcetclubs-live.vercel.app",
"*"
];

interface CorsOptions {
Expand Down
2 changes: 1 addition & 1 deletion frontend/dev-dist/sw.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ define(['./workbox-56da8dea'], (function (workbox) { 'use strict';
"revision": "3ca0b8505b4bec776b69afdba2768812"
}, {
"url": "index.html",
"revision": "0.ga61squ3cfo"
"revision": "0.qaokcgpg0eg"
}], {});
workbox.cleanupOutdatedCaches();
workbox.registerRoute(new workbox.NavigationRoute(workbox.createHandlerBoundToURL("index.html"), {
Expand Down
12 changes: 6 additions & 6 deletions frontend/src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ import App from "./App.tsx";
import "./index.css";
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
import { AuthProvider } from "./context/AuthContext.tsx";
import { registerSW } from "virtual:pwa-register";
// import { registerSW } from "virtual:pwa-register";

// Register service worker
if ("serviceWorker" in navigator) {
console.log("Registering service worker");
registerSW();
}
// if ("serviceWorker" in navigator) {
// console.log("Registering service worker");
// registerSW();
// }

const queryClient = new QueryClient();

ReactDOM.createRoot(document.getElementById("root")!).render(
<React.StrictMode>
<QueryClientProvider client={queryClient}>
<AuthProvider>
<AuthProvider>j
<App />
</AuthProvider>
</QueryClientProvider>
Expand Down

0 comments on commit 5269f81

Please sign in to comment.