Options
All
  • Public
  • Public/Protected
  • All
Menu

Module background/methods/dataTypes/objects/ObjectKeysTS

Index

Functions

Functions

  • hasKey<O>(obj: O, key: string | number | symbol): key is keyof O
  • "If the key is in the object, return true, otherwise return false."

    The keyof any is a special type that represents the union of all property names of a given type

    Type parameters

    • O

    Parameters

    • obj: O

      The object to check for the key.

    • key: string | number | symbol

      keyof any

    Returns key is keyof O

    does the given object have the given key

Generated using TypeDoc version 0.22.15, the 4/20/2022