jsx-eslint/eslint-plugin-react

ElementConfig should be used to determine props required

开放

#1,904 创建于 2018年7月26日

 (3 条评论) (6 个反应) (0 位负责人)JavaScript (2,731 个派生)batch import
flowhelp wantedtypescript

仓库指标

星标
 (9,293 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

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.

贡献者指南