first commit

This commit is contained in:
Jeannette Chin committed 2026-10-04 14:28:26 +01:00
commit 5d6023a8af
52 files changed
+5830

No files matched your search

+18
View File
@@ -0,0 +1,18 @@
"use client";
import { useRef } from "react";
import { Provider } from "react-redux";
import { makeStore, AppStore } from "../lib/store";
export default function PeopleProvider({
children,
}: {
children: React.ReactNode;
}) {
const storeRef = useRef<AppStore>(undefined);
if (!storeRef.current) {
// Create the store instance the first time this renders
storeRef.current = makeStore();
}
return <Provider store={storeRef.current}>{children}</Provider>;
}