We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Eslint detects react/prop-types rule violation in the following code:
const map = { one: { component: One, }, two: { component: Two, withMargin: true, }, } const Part = props => { if (!map[props.type]) return null const { component: Component, withMargin } = map[props.type] return <Component {...props} withMargin={withMargin} /> } Part.propTypes = { type: PropTypes.string.isRequired, }
error '.component' is missing in props validation react/prop-types error '.withMargin' is missing in props validation react/prop-types
The text was updated successfully, but these errors were encountered:
This looks like a duplicate to #1259
Sorry, something went wrong.
Yes, closing as a duplicate, thanks.
No branches or pull requests
Eslint detects react/prop-types rule violation in the following code:
The text was updated successfully, but these errors were encountered: