jsx-eslint/eslint-plugin-react

react/prefer-stateless-function works different than described in docs

Open

#1.901 aberto em 26 de jul. de 2018

Ver no GitHub
 (0 comments) (0 reactions) (0 assignees)JavaScript (2.797 forks)batch import
bughelp wanted

Métricas do repositório

Stars
 (8.630 stars)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

For the react/prefer-stateless-function rule the docs for ignorePureComponents option states:

When true the rule will ignore Components extending from React.PureComponent that use this.props or this.context.

Actually it also ignore every PureComponent that use not only props or context, but ignores every component that use this. If this is not intended I prepared a fix (GH-1902), otherwise it makes sense to update the docs.

Guia do colaborador