I have rxjs nested observables, which work fine.
this.service.save(body).subscribe(
() => {
this.dialog.confirmDialog({
title: '',
message: 'Save okay',
caption: 'OK'
})
.subscribe((yes) => {
this.service.getGoal().subscribe(
result => {
this.loading(result);
}
);
});
}
});
The code does three things. First save object, secondly popup a confirmation window. Last call service to refresh the page. I use nested subscribe here. I know it is not good in theory and I should replace them with rxjs some map function. But I just don't know how?