ts-phonenumber - v2.0.0
    Preparing search index...

    Interface PhoneNumberDesc

    Phone number description - pattern and validation info for a number type. Maps to PhoneNumberDesc in libphonenumber.

    interface PhoneNumberDesc {
        example?: string;
        pattern?: RegExp;
        possibleLengths?: number;
        possibleLengthsLocalOnly?: number;
    }
    Index

    Properties

    example?: string

    Example number matching this pattern

    pattern?: RegExp

    Compiled regular expression for matching national numbers (anchored: ^pattern$)

    possibleLengths?: number

    Bitmap of possible lengths for this number type. Bit N is set if length N is valid. Check with: (bitmap & (1 << length)) !== 0

    LengthBitmap

    possibleLengthsLocalOnly?: number

    Bitmap of possible lengths when dialing locally (without area code).

    LengthBitmap