Options
All
  • Public
  • Public/Protected
  • All
Menu

Module src/object/has

Index

Functions

Functions

Const has

  • has(obj: Record<any, any>, path: string | Array<string>): boolean
  • Has - Checks if path is a direct property of object.

    example

    has({ 'a': { 'b': 2 } }, 'a'); // returns true

    has({ 'a': { 'b': 2 } }, 'a'); // returns true

    Parameters

    • obj: Record<any, any>
    • path: string | Array<string>

    Returns boolean

    {boolean}

Generated using TypeDoc