You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not sure if this is working properly - I typed the same password in password and confirm password but the console.log for matching passwords doesn't show :(
Also when using a pattern attribute in the HTML you can verify that the content in that field matches the pattern using element.validity.patternMismatch e.g.
if (password.validity.patternMismatch) {
password.setCustomValidity('Value of field doesn't match the pattern');
} else {
password.setCustomValidity('');
}
I'm not sure if this is working properly - I typed the same password in password and confirm password but the console.log for matching passwords doesn't show :(
Also when using a pattern attribute in the HTML you can verify that the content in that field matches the pattern using element.validity.patternMismatch e.g.
Links if you're interested:
https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#the-constraint-validation-api
https://developer.mozilla.org/en-US/docs/Learn/HTML/Forms/Form_validation
The text was updated successfully, but these errors were encountered: