When trying ViewChild I am getting the error. Error is \"An argument for \'opts\' was not provided.\"
Both @ViewChild is giving the error.
it is because view child require two argument try like this
@ViewChild('nameInput', { static: false, }) nameInputRef: ElementRef; @ViewChild('amountInput', { static: false, }) amountInputRef: ElementRef;
@ViewChild('nameInput', { static: false, }) nameInputRef: ElementRef;
@ViewChild('amountInput', { static: false, }) amountInputRef: ElementRef;