fix(redux): Fixed gatsby-ipfs-web-wallet redux error

This commit is contained in:
Daniel Gonzalez
2021-06-14 19:40:47 -04:00
parent dff18ced18
commit e055b80a80
+14 -11
View File
@@ -116,15 +116,18 @@ const initialState = {
data: null
}
}
const createStore = () =>
reduxCreateStore(
reducer,
initialState,
/** Redux DevTools
* https://chrome.google.com/webstore/detail/redux-devtools/lmhkpmbekcpmknklioeibfkpmmfibljd?hl=es
*
*/
window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__()
)
let createStore
typeof window !== 'undefined'
? (createStore = () =>
reduxCreateStore(
reducer,
initialState,
/** Redux DevTools
* https://chrome.google.com/webstore/detail/redux-devtools/lmhkpmbekcpmknklioeibfkpmmfibljd?hl=es
*
*/
window.__REDUX_DEVTOOLS_EXTENSION__ &&
window.__REDUX_DEVTOOLS_EXTENSION__()
))
: (createStore = () => reduxCreateStore(reducer, initialState))
export default createStore