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

forbid-prop-types give false positive on customObject.array attribute (not PropTypes.array) #1402

Closed
gleb-lobastov opened this issue Aug 28, 2017 · 2 comments

Comments

@gleb-lobastov
Copy link

Hi. Such is the bug:

import { formPropTypes } from 'redux-form';
class SomeComponent extends React.PureComponent {
  static propTypes = {
    // 🚨  got "Prop type `array` is forbidden" error here
    myProp: formPropTypes.array.isRequired,
  };
}

package version: "0.4.0"

@jseminck
Copy link
Contributor

For anyone tackling this, I think this issue is similar to: #1389

We are not properly distinguishing between PropTypes coming from the prop-types package and custom prop-types.

@ljharb
Copy link
Member

ljharb commented Feb 4, 2022

If this is still an issue, please post eslint config as well.

@ljharb ljharb closed this as completed Feb 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants