Last week we lost a lot of time investigating an issue with ‘ion-menu’, one of the built-in controls of Ionic. The problem was that once the menu was opened it would no longer refresh it’s data.
What we do is showing some user data on the top of the menu, this data is returned with an http call from the server and updated through an observable subscription. However pushing a new value on the observable had no effect on the view although the component data was in fact updated.
As a workaround we used the built-in event bus to publish an event once the user was loaded. We handle this event on the viewcomponent and use it to explictly trigger a change detection:
More information about the ChangeDetectorRef can be found here: https://alligator.io/angular/change-detection-strategy/