jsx-eslint/eslint-plugin-react

New rule to avoid prop value with array or object creation in render

Open

#1 633 ouverte le 8 janv. 2018

Voir sur GitHub
 (17 commentaires) (10 réactions) (0 assignés)JavaScript (2 797 forks)batch import
acceptedhelp wantednew rule

Métriques du dépôt

Stars
 (8 630 stars)
Métriques de merge PR
 (Aucune PR mergée en 30 j)

Description

There is a rule for prop value with function creation (bind, function(...), or arrow function): react/jsx-no-bind But I can't find a rule for array ([]) or object ({}) creation.

It would be useful since it would help to avoid useless renders of pure components.

Guide contributeur