Why would I use RxJS interval() or timer() polling instead of window.setInterval()?
问题 Use case: Call a function every minute (60000 ms) that dispatches store action to fetch lastUpdated status of items, which upon response and filtering, updates the store, and updated store is read as an observable and displayed in the view). This needs to happen for as long as the web app is open (so indefinitely). Currently, I'm using this: this.refreshDate = window.setInterval( () => this.store.dispatch(new FetchLastUpdate()) , 60000); And when view is destroyed/dismounted, I delete the