You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

registerSchema.js 406B

1234567891011
  1. import * as Yup from "yup";
  2. export const registerSchema = Yup.object().shape({
  3. username: Yup.string().required("Username is required."),
  4. email: Yup.string().required('Email is required'),
  5. password: Yup.string().required("Password is required"),
  6. confirmPassword: Yup.string().oneOf(
  7. [Yup.ref("password"), null],
  8. "Passwords must match"
  9. ).required('Confirmation password is required'),
  10. });