You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The text was updated successfully, but these errors were encountered:
aandrejevas
changed the title
Proposal: Strongly-typed version of Object.values()
Proposal: Strongly-typed version of Object.values(). And synchronize objectKeys and objectEntries
Aug 24, 2024
It would be useful to add a strongly-typed version of Object.values().
How Object.values is defined:
How objectValues could be defined:
Also objectKeys and objectEntries definitions should be synchronized:
I would suggest changing objectEntries definition to "Type extends object" to allow passing interfaces, because I see no point in rejecting them, we are not making these calls safer by rejecting them (with or without allowing interfaces we are doing the same unsafe things https://stackoverflow.com/questions/55012174/why-doesnt-object-keys-return-a-keyof-type-in-typescript).
The text was updated successfully, but these errors were encountered: