gradum-kit - v0.1.0
    Preparing search index...

    Function getFirstDescriptorInChain

    • Function

      getFirstDescriptorInChain

      Parameters

      • object: object

        The object to search from.

      • key: PropertyKey

        The property to look for.

      Returns PropertyDescriptor

      The nearest descriptor, or undefined if nothing in the chain declares it.

      Find how a property is defined on an object or the closest ancestor that declares it, giving you the getter, setter, or value rather than just the resolved result. The search starts at the object itself and stops before Object.prototype, so inherited built-ins are never returned.