@alextheman/utility - v4.3.5
    Preparing search index...

    Function omitProperties

    • Omits properties from a given object.

      Type Parameters

      • ObjectType extends Record<string, unknown> | Readonly<Record<string, unknown>>

        The type of the input object.

      • KeysToOmit extends string | number | symbol

        A type representing the keys to omit from the object.

      Parameters

      • object: ObjectType

        The object to omit properties from.

      • keysToOmit: KeysToOmit | readonly KeysToOmit[]

        The keys to omit from the object. Can either be a single string to omit one, or an array to omit multiple.

      Returns Omit<ObjectType, KeysToOmit>

      An object with a new reference in memory, with the properties omitted.