Skip to content

Commit c768f4f

Browse files
committed
Make props more explicit
1 parent 3c9cc45 commit c768f4f

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

modules/Router.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ var Router = createClass({
173173
},
174174

175175
render() {
176-
var { routes, params, components } = this.state;
176+
var { isTransitioning, location, routes, params, components } = this.state;
177177
var element = null;
178178

179179
if (components) {
@@ -183,7 +183,13 @@ var Router = createClass({
183183

184184
var route = routes[index];
185185
var routeParams = getRouteParams(route, params);
186-
var props = Object.assign({}, this.state, { route, routeParams });
186+
var props = {
187+
isTransitioning,
188+
location,
189+
params,
190+
route,
191+
routeParams
192+
};
187193

188194
if (isValidElement(element)) {
189195
props.children = element;

0 commit comments

Comments
 (0)