Answer the question
In order to leave comments, you need to log in
Rxjs - how to do data change monitoring?
https://stackblitz.com/edit/typescript-l75wse?file...
import { Observable, from } from "rxjs";
const arr = [1,2,3]
var observable = from(arr)
arr.push(22)
setTimeout(() => {
var subscription = observable.subscribe(
(x:any) => console.log(x)
)
},2000);
arr.push(333)
setTimeout(() => arr.push(4444), 5000)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question