Skip to content

Commit

Permalink
Implement examples
Browse files Browse the repository at this point in the history
  • Loading branch information
zalmoxisus committed Jan 1, 2016
1 parent e718ae7 commit eb18fc4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion examples/counter/store/configureStore.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
import { createStore, applyMiddleware, compose } from 'redux';
import thunk from 'redux-thunk';
import invariant from 'redux-immutable-state-invariant';
import devTools from 'remote-redux-devtools';
import reducer from '../reducers';

export default function configureStore(initialState) {
const finalCreateStore = compose(
applyMiddleware(invariant(), thunk)
applyMiddleware(invariant(), thunk),
devTools()
)(createStore);

const store = finalCreateStore(reducer, initialState);
Expand Down
3 changes: 2 additions & 1 deletion examples/todomvc/store/configureStore.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { createStore } from 'redux';
import devTools from 'remote-redux-devtools';
import rootReducer from '../reducers';

export default function configureStore(initialState) {
const store = createStore(rootReducer, initialState);
const store = devTools()(createStore)(rootReducer, initialState);

if (module.hot) {
// Enable Webpack hot module replacement for reducers
Expand Down

0 comments on commit eb18fc4

Please sign in to comment.