npm.io
5.0.8 • Published 2 years ago

@types/joi-phone-number

Licence
MIT
Version
5.0.8
Deps
2
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/joi-phone-number

Summary

This package contains type definitions for joi-phone-number (https://github.com/Salesflare/joi-phone-number).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/joi-phone-number.

index.d.ts

/// <reference types="node" />
import { Extension, Reference, Root, StringSchema } from "joi";

declare module "joi" {
    interface PhoneNumberOptions {
        defaultCountry?: string[] | string | Reference | undefined;
        strict?: boolean | Reference | undefined;
        format?: "e164" | "international" | "national" | "rfc3966" | Reference | undefined;
    }

    interface StringSchema {
        phoneNumber(options?: PhoneNumberOptions): this;
    }
}

interface StringExtension extends Extension {
    type: "string";
    base: StringSchema;
}

declare function JoiStringFactory(joi: Root): StringExtension;
export = JoiStringFactory;

Additional Details

  • Last updated: Tue, 07 Nov 2023 0337 GMT
  • Dependencies: @types/node, joi

Credits

These definitions were written by Marvin Witt, and James Lismore.