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

[Fix]: fix prop-types Cannot read property 'type' of undefined error when destructured param #2807

Merged
merged 1 commit into from Sep 27, 2020

Conversation

minwe
Copy link
Contributor

@minwe minwe commented Sep 27, 2020

Summary

This pr fixes: #2804, #2805.

Function parameter will have ExperimentalRestProperty(JSX) and which do not have property value.
It will cause undefined property error.

Copy link
Member

@ljharb ljharb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@ljharb ljharb merged commit 2b0d70c into jsx-eslint:master Sep 27, 2020
@adnasa
Copy link
Contributor

adnasa commented Oct 5, 2020

it is possible that this fixes #2809
as well. I just migrated to 7.21.3 and warning stopped emitting.

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

Successfully merging this pull request may close these issues.

TypeError: Cannot read property 'type' of undefined in prop-types
3 participants