Published on

TotalTypescript - Create your own 'objectKeys' function using generics and the 'keyof' operator

Authors

TotalTypescript - Create your own 'objectKeys' function using generics and the 'keyof' operator

TotalTypescript - Create your own 'objectKeys' function using generics and the 'keyof' operator

Object.keys has an especific type issue in Typescript where it doesnt say correctly the keys of an object (key as string), which shows an error when trying to access inside of a forEach for example when you reuse the object:

Fallback text 1