This commit is contained in:
Stuart Colville 2015-07-27 15:29:06 +01:00
Родитель b21837986b
Коммит 11de690d98
1 изменённых файлов: 5 добавлений и 2 удалений

Просмотреть файл

@ -1,8 +1,11 @@
import { createStore, combineReducers } from 'redux';
import { createStore, combineReducers, applyMiddleware } from 'redux';
import thunk from 'redux-thunk';
import * as reducers from 'reducers';
export function createReduxStore() {
return createStore(combineReducers(reducers));
const reducer = combineReducers(reducers);
const finalCreateStore = applyMiddleware(thunk)(createStore);
return finalCreateStore(reducer);
}
export default createReduxStore();