// data
let errors ={
"email":"Password is required",
"phonenumber":"Password is required",
"password":"Password is required"
}
//how to loop object
Object.entries(errors).forEach(error => {
console.log(error)
})
//results
['email', 'Password is required']
['phonenumber', 'Password is required']
['password', 'Password is required']