jsx-eslint/eslint-plugin-react

ElementConfig should be used to determine props required

Open

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

在 GitHub 查看
 (3 评论) (6 反应) (0 负责人)JavaScript (8,630 star) (2,797 fork)batch import
flowhelp wantedtypescript

描述

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.

贡献者指南