Closed parshap closed 9 years ago
Thanks for letting me know.
It's assigned to props.pattern as a form of caching. We could cache them elsewhere. I don't believe there is really any good use for children to be passed the pattern as a prop.
In fact, we actually remove that prop before passing props to the child. So it is likely safe to just cache this directly on the element itself.
Your issue should be fixed in master
. Try it out.
Full React 0.14 support is coming soon.
Directly mutating props of a component is not possible in React 0.14. This was deprecated in React 0.13:
I was testing the React 0.14 beta and found
react-router-component
currently does this inmatchRoutes.js
, which throws an error when running withreact@0.14.0-beta
:props.pattern
seems to be only be used in the same context, two lines down, so I think it would be an easy fix to just use a local variablevar pattern
instead of mutatingprops.pattern
. This may be a breaking change though, as route components will no longer expose the pattern prop (though not sure if anyone actually depended on this behavior).