checkValidity

Indicates the validity of the value of the element. If the value is invalid, this method also fires the invalid event on the element.

https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/checkValidity