React-router: support for react 0.15.2 - https://fb.me/react-unknown-prop

Created on 1 Jul 2016  路  7Comments  路  Source: ReactTraining/react-router

The new React version 0.15.2 has introduced a new warning regarding passing props to children: https://fb.me/react-unknown-prop

Version

2.5.2

Test Case

git clone https://github.com/FredericHeem/starhackit && cd starhackit/client && npm i && npm start

Steps to reproduce

Expected Behavior

No react warnings

Actual Behavior

warning.js:44 Warning: Unknown props history, location, params, route, routeParams, routes on

tag. Remove these props from the element. For details, see https://fb.me/react-unknown-prop

Most helpful comment

All 7 comments

You're getting that error because _you're_ passing down the route props to the DOM nodes.

Thanks a lot.

This is a pattern taken from the example: https://github.com/reactjs/react-router/blob/master/examples/huge-apps/app.js#L23
To reproduce the issue:

npm start
open http://localhost:8080/huge-apps/

I agree with @FredericHeem this error is occurring in the example https://github.com/reactjs/react-router/blob/master/examples/huge-apps/app.js#L23 with the React 15.2

Can someone reopen this issue as it is definitely an issue ?

This is not inherent with the router. It's an issue with an example. This bug report is for the wrong thing. A PR for fixing the example is what's needed instead.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

yormi picture yormi  路  3Comments

tomatau picture tomatau  路  3Comments

hgezim picture hgezim  路  3Comments

misterwilliam picture misterwilliam  路  3Comments

alexyaseen picture alexyaseen  路  3Comments