Typescript 在 VScode 中工作,但 eslint 为推断类型发出 react/prop-types 错误

Typescript working in VScode, but eslint emitting react/prop-types error for inferred types

在 VScode 中它工作正常,因为可以从 LeadInfo.

推断出类型

但是,Eslint 发出 missing props validation 的错误

顺便说一下,Column 来自 React-table,我们已经遵循了 https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-table

react-table 建议设置

在你的 eslint 配置中关闭 react/prop-types 规则,如果你使用 TS

则开启它没有多大意义