New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support react 16.6 for react-router v3 #6806
Support react 16.6 for react-router v3 #6806
Conversation
Awesome work! I'll try to get this pushed out today. |
Thank you 🎉🎉🎉 |
Thank you |
@timdorr with the fixes for component types does this mean react-router 3 now officially supports react-redux 7.x? |
@dlong500 I hope it could. If you encounter any problem, please create an issue. I'll try to fix it if possible. |
Yes, I believe it should be good with connected components now. |
Thanks @timdorr. I ran into the same issue yesterday, and today I see the fix is out :-) I can confirm, react-router@3.2.2 works with react@16.8 and react-redux@7.1 |
Issues
#6766
Why
react router v3 supports components as props with format
{ [name]: component }
according to this. However, newer react component may also be an objects, so it would make react-router v3 broken.How to fix
Use
isValidElementType
is distinguish{ [name]: component }
and react components forReact.memo
,React.forwardRef
,React.Fragment
and so on