D.keys type is correct for object with numeric indexes
Closed this issue · 1 comments
Nodonisko commented
D.keys
type is incorrect:
const keys = D.keys({ 1: 'ahoj', 2: 'ahoj2' });
console.log(keys);
This will print [ '1', '2' ]
but type for keys
is readonly (1 | 2)[]
which is wrong because it shouldn't be numbers but strings: readonly ('1' | '2')[]
Nodonisko commented
It's probably related to this microsoft/TypeScript#39543