i want to get this value and check with exist user password:
const Users =[{
userName: 'Hasan1934',
password: 'Qwx32dksa'
}]
and Input value :
const UserName = document.getElementById("username-field")
const Password = document.getElementById("password-field")
and condition :
for (let index = 0; index < Users.length; index++) {
let ArrayItem = Users[index];
if (UserName === ArrayItem.userName && Password === arrayItem.password ) {
// console.log("your in !!!!!!!!!!!**********");
break;}}
it dosent work for me
const UserNameHtml = (document.getElementById("username-field") as HTMLInputElement).value
Try this