angular scroll to element horizontally code example
Example 1: angular scroll to element horizontally
scrollLeft(){
this.widgetsContent.nativeElement.scrollLeft -= 150;
}
scrollRight(){
this.widgetsContent.nativeElement.scrollLeft += 150;
}
Example 2: angular scroll to element horizontally
@ViewChild('widgetsContent') widgetsContent: ElementRef;