mirror of
https://github.com/lemeow125/React-NotesApp.git
synced 2024-11-16 22:19:27 +08:00
Readded Redux to track login state
This commit is contained in:
parent
0daa8cfa72
commit
61bdec145b
2 changed files with 13 additions and 3 deletions
5
src/Features/Redux/Store/Store.tsx
Normal file
5
src/Features/Redux/Store/Store.tsx
Normal file
|
@ -0,0 +1,5 @@
|
|||
import { configureStore } from "@reduxjs/toolkit";
|
||||
|
||||
export default configureStore({
|
||||
reducer: {},
|
||||
});
|
|
@ -10,6 +10,9 @@ import Login from "./Routes/Login/Login";
|
|||
|
||||
import { QueryClient, QueryClientProvider } from "react-query";
|
||||
|
||||
import { Provider } from "react-redux";
|
||||
import Store from "./Features/Redux/Store/Store";
|
||||
|
||||
const queryClient = new QueryClient();
|
||||
|
||||
const router = createBrowserRouter([
|
||||
|
@ -33,9 +36,11 @@ const root = ReactDOM.createRoot(
|
|||
|
||||
root.render(
|
||||
<React.StrictMode>
|
||||
<QueryClientProvider client={queryClient}>
|
||||
<RouterProvider router={router} />
|
||||
</QueryClientProvider>
|
||||
<Provider store={Store}>
|
||||
<QueryClientProvider client={queryClient}>
|
||||
<RouterProvider router={router} />
|
||||
</QueryClientProvider>
|
||||
</Provider>
|
||||
</React.StrictMode>
|
||||
);
|
||||
|
||||
|
|
Loading…
Reference in a new issue