how to use component methods through viewChild code example
Example: angular viewchild input element value
// in html
<input #input type="text">
// in .ts
@ViewChild('input') input:ElementRef;
//Output value
console.log(this.input.nativeElement.value);