diff options
| author | 2021-02-21 07:35:29 +0200 | |
|---|---|---|
| committer | 2021-02-21 07:35:29 +0200 | |
| commit | b1f05fa57c862ce8219e5ca464e794353261f842 (patch) | |
| tree | ff67e7265ad52099181ceb0bf2a0af36f0525fdd /src/App.tsx | |
| parent | Move hCaptcha types library to dev-dependencies (diff) | |
Migrate from public state map to Redux
Diffstat (limited to 'src/App.tsx')
| -rw-r--r-- | src/App.tsx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/App.tsx b/src/App.tsx index 523e583..14e5329 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -3,6 +3,7 @@ import React, { Suspense } from "react"; import { jsx, css, Global } from "@emotion/react"; +import { Provider } from "react-redux"; import { BrowserRouter as Router, Route, @@ -14,6 +15,7 @@ import { PropagateLoader } from "react-spinners"; import { CSSTransition, TransitionGroup } from "react-transition-group"; import globalStyles from "./globalStyles"; +import { store } from "./store/form/store"; const LandingPage = React.lazy(() => import("./pages/LandingPage")); const FormPage = React.lazy(() => import("./pages/FormPage")); @@ -51,7 +53,7 @@ function App(): JSX.Element { {routes.map(({path, Component}) => ( <Route exact key={path} path={path}> <Suspense fallback={<PageLoading/>}> - <Component/> + {path == "/form/:id" ? <Provider store={store}><Component/></Provider> : <Component/>} </Suspense> </Route> ))} |