Skip to main content

reactiveDivide

Alternatives: div$$, divide$$

Types

function reactiveDivide(
a: IObservable<number>,
b: IObservable<number>,
): IObservable<number>

Definition

Creates an Observable which performs a division (/) between the values sent by two Observables, and emits the result.

Diagram

Example

Perform the "division" of two Observables

const subscribe = reactiveDivide(
single(10),
single(5),
);

subscribe((value: number) => {
console.log(value);
});

Output:

2