palantir/blueprint

TagInput should have a string-only variant with simpler prop types

开放

#4,390 创建于 2020年10月27日

 (0 条评论) (0 个反应) (0 位负责人)TypeScript (2,167 个派生)batch import
Package: coreType: enhancementhelp wanted

仓库指标

星标
 (20,263 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

Working with onRemove: (value: React.ReactNode, index: number) is inconvenient under TypeScript's strict compiler options. Even when the values prop is string[], you are either forced to type cast the removed value to string or use the index parameter to index into your values array. We should make the simple case easier to work with, either with a new component API or changing the existing component to be parameterized by its data type <T>.

贡献者指南