Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "utils/property-descriptors/docs/types/index.d"

Index

Functions

Export assignment getOwnPropertyDescriptors

  • getOwnPropertyDescriptors(value: any): PropertyDescriptorMap
  • Returns an object's own property descriptors.

    Notes

    • In contrast to the built-in Object.getOwnPropertyDescriptors(), this function returns an empty object if provided undefined or null, rather than throwing an error.

    Parameters

    • value: any

      input object

    Returns PropertyDescriptorMap

    property descriptors

    Example

    var obj = {
        'beep': 'boop',
        'foo': 3.14
    };
    
    var desc = getOwnPropertyDescriptors( obj );
    // returns {...}