Skip to content
This repository has been archived by the owner on Jan 2, 2018. It is now read-only.

Commit

Permalink
Merge pull request #13 from rocjs/bug/react-router-redux
Browse files Browse the repository at this point in the history
Fixes so React Router Redux is used on the server and in production
  • Loading branch information
andreasrs committed May 6, 2016
2 parents d1c9df8 + 7750a41 commit 32cc11c
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ export default function createReduxStore(reducers, ...middlewares) {
(history, initialState) => {
let finalCreateStore;

// Add the react-router-redux middleware
middlewares.push(routerMiddleware(history));

if (__DEV__ && __WEB__) {
const { persistState } = require('redux-devtools');
const createLogger = require('redux-logger');
Expand All @@ -32,8 +35,6 @@ export default function createReduxStore(reducers, ...middlewares) {

const debugMiddlewares = [logger];

// Add the react-router-redux middleware
middlewares.push(routerMiddleware(history));
const devTools = window.devToolsExtension
? window.devToolsExtension()
// TODO Enable maxAge support here. Will require a fix for validations in roc
Expand Down

0 comments on commit 32cc11c

Please sign in to comment.