2020-01-09 04:34:58 +01:00
|
|
|
import { createStore, applyMiddleware } from 'redux'
|
|
|
|
import thunkMiddleware from 'redux-thunk'
|
|
|
|
import { composeWithDevTools } from 'remote-redux-devtools'
|
|
|
|
import rootReducer from '../ducks'
|
2016-04-14 00:28:44 +02:00
|
|
|
|
2020-01-09 04:34:58 +01:00
|
|
|
export default function configureStore (initialState) {
|
2019-07-11 16:57:06 +02:00
|
|
|
const composeEnhancers = composeWithDevTools({
|
|
|
|
name: 'MetaMask',
|
|
|
|
hostname: 'localhost',
|
|
|
|
port: 8000,
|
|
|
|
realtime: Boolean(process.env.METAMASK_DEBUG),
|
|
|
|
})
|
|
|
|
return createStore(rootReducer, initialState, composeEnhancers(
|
|
|
|
applyMiddleware(
|
|
|
|
thunkMiddleware,
|
|
|
|
),
|
|
|
|
))
|
2016-04-14 00:28:44 +02:00
|
|
|
}
|