UNPKG

yup-phone-js

Version:
13 lines (12 loc) 505 B
import { YupPhoneOptions } from "./YupPhoneOptions"; declare module "yup" { interface StringSchema { /** * Check the string is a valid phone number * * @param {YupPhoneOptions|undefined} [options=undefined] The options for the validation * @param {String} [errorMessage=DEFAULT_MESSAGE] The error message for if the validation fails. */ phone(options?: YupPhoneOptions | undefined, errorMessage?: string): StringSchema; } }