In one of my controllers I have :
@HostListener('window:resize')
onResize() {
this.currentWindowWidth = window.innerWidth;
}
and based on the window Width, I render different views. One of which needs to do some calculations. But since the change detection mechanism fires too often, this really slows down the app and there's a delay.
How are such situations managed best?