UNPKG

container.ts

Version:
15 lines (14 loc) 606 B
import validator from "validator"; import { Field } from "../field"; /** Validate.isMobilePhone options. */ export interface IIsMobilePhone extends validator.IsMobilePhoneOptions { /** Locale used by validator, defaults to en-GB. */ locale?: validator.MobilePhoneLocale; } /** Wrapper for validator isMobilePhone. */ export declare function isMobilePhone(value?: string, options?: IIsMobilePhone): string; export declare class MobilePhoneField extends Field<string> { protected readonly options: IIsMobilePhone; constructor(options?: IIsMobilePhone); validate(value: string): string; }