monorouter
monorouter copied to clipboard
Issue with examples running with react 0.13.3
If I try to use the examples with react and change to the updated version 0.13.3
I get the following error:
Cannot read property '__reactAutoBindMap' of undefined
Hi, I was playing around with this as well on the monorouter flux example and found that if I use react v 0.12.* I get the following warning
Warning: Something is calling a React component directly. Use a factory or JSX instead. See: http://fb.me/react-legacyfactory
This link states that the error is as follows: You probably came here because your code is calling your component as a plain function call. This is now deprecated:
When I change to react v 0.13, I also get the error, and as we can see this deprecated patterns no longer works http://facebook.github.io/react/blog/2015/03/10/react-v0.13.html
I guess this means we cannot call with a function that simply renders with this.render() as in the examples here and the monorouter-flux examples
I traced the problem down to monorouter-react in engine.js renderToStrong() method, so not sure if it is a problem here, or that you need to call React.createFactory on your component before passing it to this.render