ConditionalPick and ConditionalKeys break on types with index signatures
Author: ettmetalCreated Aug 15, 2026Updated Aug 15, 2026
Labelsbug
Bug description
When using ConditionalPick / ConditionalKeys with types which include an index signature for an unknown typed property, the created type will never include any results, unless unknown is passed as a condition, at which point, only those index signature keys will be part of the created type.
Expected behaviour: the created type includes all keys that can be determined at compile time, optionally also including any index signature properties.
Repro
Source: sindresorhus/type-fest