jsx-eslint/eslint-plugin-react

ElementConfig should be used to determine props required

Open

#1904 aperta il 26 lug 2018

Vedi su GitHub
 (3 commenti) (6 reazioni) (0 assegnatari)JavaScript (2797 fork)batch import
flowhelp wantedtypescript

Metriche repository

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

Descrizione

ESLint currently uses ElementProps to determine what types are required by a component with Flow-annotated props, but it should be using ElementConfig instead.

See Using Default Props for Functional Components in Flow's docs for an explanation of why. See also their comparison of ElementProps and ElementConfig.

@ljharb suggested I open an issue here to get it changed.

Guida contributor