• A wrapper around makeSubscriptionPromise that helps to build multiple promises which listen to the same subscription.

    Type Parameters

    • SubscriptionType

    Parameters

    • args: TerminationOptions<SubscriptionType>[]

      An array of objects each of which provides the arguments for creation of one promise.

    Returns {
        promises: Promise<SubscriptionType>[];
        subscription: ((value) => void);
    }

    An object containing both a subscription callback and an array of promises which resolve or reject depending on the values pushed to the callback.

    • promises: Promise<SubscriptionType>[]
    • subscription: ((value) => void)
        • (value): void
        • Parameters

          • value: SubscriptionType

          Returns void