Angular – two subscriptions in ngOnInit result in object ‘undefined’

If you want to return observables in a sequential manner, you shouldn’t nest your subscribe() methods. Instead, we should be using RxJS’s mergeMap to map over the observable values from the activatedRoute into an inner observable, which is assigned to the newsID property. Then, we call the getSectors() method from _newswireService, and the observables are … Read more

Am I getting the steps right for verifying a user’s Android in-app subscription?

As it turns out, my steps were not correct. It took me weeks to figure this out and it doesn’t seem to be documented anywhere else. You’re welcome: Create a Web Application account in the Google APIs Console. Put any website as a “redirect URI”; it doesn’t matter since you will not really be using … Read more

Angular/RxJS When should I unsubscribe from `Subscription`

TL;DR For this question there are two kinds of Observables – finite value and infinite value. http Observables produce finite (1) values and something like a DOM event listener Observable produces infinite values. If you manually call subscribe (not using async pipe), then unsubscribe from infinite Observables. Don’t worry about finite ones, RxJs will take … Read more