jsx-eslint/eslint-plugin-react

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

Open

#1633 aperta il 8 gen 2018

Vedi su GitHub
 (17 commenti) (10 reazioni) (0 assegnatari)JavaScript (2797 fork)batch import
acceptedhelp wantednew rule

Metriche repository

Star
 (8630 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

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.

Guida contributor