react-router-redux
Advanced tools
Comparing version 4.0.1 to 4.0.2
@@ -24,7 +24,9 @@ 'use strict'; | ||
* if you have asynchronously-loaded routes, so reading from and relying on | ||
* this state it is discouraged. | ||
* this state is discouraged. | ||
*/ | ||
function routerReducer() { | ||
var state = arguments.length <= 0 || arguments[0] === undefined ? initialState : arguments[0]; | ||
var _ref = arguments[1]; | ||
var _ref = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1]; | ||
var type = _ref.type; | ||
@@ -31,0 +33,0 @@ var payload = _ref.payload; |
{ | ||
"name": "react-router-redux", | ||
"version": "4.0.1", | ||
"version": "4.0.2", | ||
"description": "Ruthlessly simple bindings to keep react-router and redux in sync", | ||
@@ -5,0 +5,0 @@ "main": "lib/index", |
@@ -27,3 +27,3 @@ # react-router-redux | ||
[history](https://github.com/reactjs/history) + `store` ([redux](https://github.com/rackt/redux)) → [**react-router-redux**](https://github.com/reactjs/react-router-redux) → enhanced [history](https://github.com/reactjs/history) → [react-router](https://github.com/reactjs/react-router) | ||
[history](https://github.com/reactjs/history) + `store` ([redux](https://github.com/reactjs/redux)) → [**react-router-redux**](https://github.com/reactjs/react-router-redux) → enhanced [history](https://github.com/reactjs/history) → [react-router](https://github.com/reactjs/react-router) | ||
@@ -30,0 +30,0 @@ ## Tutorial |
@@ -15,5 +15,5 @@ /** | ||
* if you have asynchronously-loaded routes, so reading from and relying on | ||
* this state it is discouraged. | ||
* this state is discouraged. | ||
*/ | ||
export function routerReducer(state = initialState, { type, payload }) { | ||
export function routerReducer(state = initialState, { type, payload } = {}) { | ||
if (type === LOCATION_CHANGE) { | ||
@@ -20,0 +20,0 @@ return { ...state, locationBeforeTransitions: payload } |
37261