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

React.pureComponent ignored (React v15.3.0) #737

Closed
ozum opened this issue Aug 3, 2016 · 3 comments
Closed

React.pureComponent ignored (React v15.3.0) #737

ozum opened this issue Aug 3, 2016 · 3 comments
Assignees
Labels

Comments

@ozum
Copy link

ozum commented Aug 3, 2016

Using eslint-plugin-react v6.0.0 "react/prop-types": ["error"] rule does not generate error for React.PureComponent which is added in react v15.3.0.

Example:
"react/prop-types": ["error"]

import React from 'react';

export default class extends React.PureComponent {
  render() {
    return (
      <div>
        <span>{this.props.no}</span>
      </div>
    );
  }
}
@ozum ozum changed the title React.pureComponent (React v15.3.0) React.pureComponent ignored (React v15.3.0) Aug 3, 2016
@lencioni
Copy link
Collaborator

lencioni commented Aug 3, 2016

Thanks for the report! I think we need to update some of our utility methods to better detect these new things. e.g. https://github.com/yannickcr/eslint-plugin-react/blob/763382f8d4ec5961c765bbb71cd2698016da5b53/lib/util/Components.js#L195

@ozum would you be interested in submitting a PR for this?

@lencioni lencioni added the bug label Aug 3, 2016
@ozum
Copy link
Author

ozum commented Aug 3, 2016

Unfortunately,I don't have enough React experience for this PR. This is my first week with React.

@yannickcr
Copy link
Member

Working on it

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

No branches or pull requests

3 participants