feat: confirm access page and persist redux store
This commit is contained in:
23
providers/ReduxProvider.tsx
Normal file
23
providers/ReduxProvider.tsx
Normal file
@ -0,0 +1,23 @@
|
||||
"use client";
|
||||
|
||||
import { ReactNode } from "react";
|
||||
import { Provider } from "react-redux";
|
||||
import { PersistGate } from "redux-persist/integration/react";
|
||||
import { persistor, store } from "@/lib/store";
|
||||
|
||||
type Props = {
|
||||
children: ReactNode;
|
||||
};
|
||||
|
||||
export default function ReduxProvider({ children }: Props) {
|
||||
return (
|
||||
<Provider store={store}>
|
||||
{" "}
|
||||
<PersistGate
|
||||
loading={null}
|
||||
persistor={persistor}>
|
||||
{children}
|
||||
</PersistGate>
|
||||
</Provider>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user