Skip to content
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

[ListItem] @reach/router Link is not accepted as a component prop #807

Closed
luisrudge opened this issue Oct 12, 2018 · 4 comments
Closed

[ListItem] @reach/router Link is not accepted as a component prop #807

luisrudge opened this issue Oct 12, 2018 · 4 comments
Labels
Milestone

Comments

@luisrudge
Copy link
Contributor

luisrudge commented Oct 12, 2018

Description

Using @reach/router's Link component fails the propTypes validation:

Warning: Failed prop type: Invalid prop `component` supplied to `ListItem`.

Link to a gist or code sample where the issue can be reproduced

https://codesandbox.io/s/pjjpmw7zv7

@luisrudge
Copy link
Contributor Author

found the issue here: facebook/prop-types#200
it's because of the forwardRef thing.. it kinda messes up the component type.

@luisrudge
Copy link
Contributor Author

@mlaursen what do you want to do with this? can I send a PR that adds PropTypes.object to the proptypes definition for those props?

@mlaursen
Copy link
Owner

Sorry for the delay!

That's interesting. I think updating this to be PropTypes.object will be a good workaround then. I'd be happy to accept a PR

@mlaursen
Copy link
Owner

This should now be fixed in v1.7.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants