Library API
    Preparing search index...

    Function ownKeys

    • Returns an array of all enumerable property keys for an object.

      Type Parameters

      Parameters

      • json: T

        The object to extract keys from

      • all: boolean = false

        Whether to include keys from the prototype chain

      Returns KeyOf<T>[]

      An array of property keys

      const keys = ownKeys({ a: 1, b: 2 });