angular host listener resize code example
Example 1: typescript on window resize
@HostListener('window:resize', ['$event'])
onResize(event) {
event.target.innerWidth;
}
Example 2: how to run resize event only on client side angular
<div (window:resize)="onResize($event)"