feat: build production-ready wtr weather PWA
This commit is contained in:
15
components/layout/providers.tsx
Normal file
15
components/layout/providers.tsx
Normal file
@@ -0,0 +1,15 @@
|
||||
"use client";
|
||||
|
||||
import { useState, type PropsWithChildren } from "react";
|
||||
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
|
||||
import { ServiceWorkerRegister } from "@/components/layout/service-worker-register";
|
||||
|
||||
export function Providers({ children }: PropsWithChildren) {
|
||||
const [queryClient] = useState(() => new QueryClient());
|
||||
return (
|
||||
<QueryClientProvider client={queryClient}>
|
||||
{children}
|
||||
<ServiceWorkerRegister />
|
||||
</QueryClientProvider>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user