I have a piece of code that looks like this:
getPersons().subscribe( persons => { for (const person of persons) { getAddress(perso
Try this approach
methodOne() { getPersons().subscribe( persons => { for (const person of persons) { getAddress(person.id).subscribe( address => { person.address = address; } ); } } ); } async methodTwo() { await methodOne(); doSomethingWithAddresses(); }