Skip to content

Utils / objectKeys

Function: objectKeys() ​

objectKeys<T>(value: T): <Type>(value: Type) => `${Exclude<keyof Type, symbol>}`[]

将对象中所有的key转为数组

Type Parameters ​

Type Parameter
T extends object

Parameters ​

ParameterType
valueT

Returns ​

<Type>(value: Type): `${Exclude<keyof Type, symbol>}`[]

Type Parameters ​

Type Parameter
Type extends object

Parameters ​

ParameterType
valueType

Returns ​

`${Exclude<keyof Type, symbol>}`[]

MIT Licensed