Created
January 17, 2021 03:04
-
-
Save leonmezu1/f6d11d67353cd22f19fd7a0ac587c822 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { createStore, applyMiddleware, compose } from "redux"; | |
import thunk from "redux-thunk"; | |
import reducer from "./reducers"; | |
const store = createStore( | |
reducer, | |
compose( | |
applyMiddleware(thunk), | |
typeof window === "object" && | |
typeof window.__REDUX_DEVTOOLS_EXTENSION__ !== "undefined" | |
? window.__REDUX_DEVTOOLS_EXTENSION__() | |
: (f) => f | |
) | |
); | |
export default store; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment