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

    Function createProxy

    • Function

      createProxy

      Type Parameters

      • SelfType extends object

        The type of the primary object.

      • ProxiedType extends object

        The type of the fallback object.

      Parameters

      • self: SelfType

        The primary object, consulted first.

      • proxied: ProxiedType

        The fallback object, used for anything the primary lacks.

      Returns SelfType & ProxiedType

      A proxy exposing both objects as one.

      Combine two objects into one, without copying anything. Reads and writes go to the first object when it already has the property, and fall through to the second otherwise — so the first shadows the second, and both stay live rather than being snapshotted.