validate({ username: "John_Doe", email: "doe@gmail.com", password: "not-my-favorite", }) .then((res) => console.log(res)); // TypeError: age is a required field Array validation For array type, Yup has several useful extensions to validate its values. For example, you can ...