Learn RxJS
Search…
AsyncSubject

Emits its last value on completion

Examples

Example 1: simple AsyncSubject

// RxJS v6+
import { AsyncSubject } from 'rxjs';
const sub = new AsyncSubject();
sub.subscribe(console.log);
sub.next(123); //nothing logged
sub.subscribe(console.log);
sub.next(456); //nothing logged
sub.complete(); //456, 456 logged by both subscribers

Additional Resources

Copy link
Outline
Emits its last value on completion
Examples
Additional Resources