11597655d9
* Refactored the store so that it doesnt use getInitialProps * Applied the changes in the _app file * Refactored the wrapper so that it uses the new store flow * Removed the old redux syntax Instead of passing the state from the parent component, I have used the new redux hooks to retrieve the current state. * The clock no longer requires state to be passed too * Updated the variable names * forgot to bring back hot reloading * Applied requested change.
12 lines
284 B
JavaScript
12 lines
284 B
JavaScript
import { Provider } from 'react-redux'
|
|
import { useStore } from '../store'
|
|
|
|
export default function App({ Component, pageProps }) {
|
|
const store = useStore(pageProps.initialReduxState)
|
|
|
|
return (
|
|
<Provider store={store}>
|
|
<Component {...pageProps} />
|
|
</Provider>
|
|
)
|
|
}
|