while using this code:
firstNameControl.valueChanges.debounceTime(1000).subscribe(value => this.setFirstNameMessage(firstNameControl));
The validation message is only displayed if the value in the input box changes as valueChanges method only watches value change in the input box. I want to display the message on focus events also.
You can try out the
Something like this
Or
This will return a Boolean and based on that you can show your message.