keysOf
Size
0.07 kb
Same as Object.keys
but with proper types
import { keysOf } from 'crustack/utils'
const object = { a: 1, b: '' }
const keys = keysOf(object)// Array<'a' | 'b'>
const keys = Object.keys(object)// Array<string>
Same as Object.keys
but with proper types
import { keysOf } from 'crustack/utils'
const object = { a: 1, b: '' }
const keys = keysOf(object)// Array<'a' | 'b'>
const keys = Object.keys(object)// Array<string>