For testing purposes, I\'m creating Observable objects that replace the observable that would be returned by an actual http call with H
Observable
H
What you want is a timer:
// RxJS v6+ import { timer } from 'rxjs'; //emit [1, 2, 3] after 1 second. const source = timer(1000).map(([1, 2, 3]); //output: [1, 2, 3] const subscribe = source.subscribe(val => console.log(val));