Validación del número de teléfono en YUP
Yup.object({
phone: Yup.string()
.required("This field is Required")
.matches(
/^((\\+[1-9]{1,4}[ \\-]*)|(\\([0-9]{2,3}\\)[ \\-]*)|([0-9]{2,4})[ \\-]*)*?[0-9]{3,4}?[ \\-]*[0-9]{3,4}?$/,
"Phone number is not valid"
)
})
ashirbad-panigrahi