Giter VIP home page Giter VIP logo

libphonenumber-js-utils's Introduction

Libphonenumber-js-utils · npm version Build Status

What is it

This repo is a compiled and minified version of the utilities functions from the googlei18n's libphonenumber library. The functions are exposed to window.intlTelInputUtils inside browser environment.

How to use

  • Add libphonenumber-js-utils to the package dependency.
  • import 'libphonenumber-js-utils'; in your code.
  • The functions will be available in window.intlTelInputUtils.

Features inside it

Name Type Description
formatNumber Function Format Phone number according to country
getExampleNumber Function Get example phonenumber of a country
getExtension Function
getNumberType Function Get the type of number entered like FIXED_LINE, MOBILE, etc.
getValidationError Function Get the validation error
isValidNumber Function Check if a number is valid for a country
numberFormat Enum Possible Values:
NATIONAL
INTERNATIONAL
numberType Enum Possible Values:
FIXED_LINE
MOBILE
UNKNOWN
validationError Enum Possible Values:
IS_POSSIBLE
INVALID_COUNTRY_CODE
TOO_SHORT
TOO_LONG
NOT_A_NUMBER

How to build it

Install Dependencies

Install maven and ant. For MacOS

brew install ant
brew install maven
sh scripts/build-dependencies.sh

Compile

sh scripts/execute.sh

Contributors

@superhit0 @patw0929 @nutboltu

libphonenumber-js-utils's People

Contributors

madurapradeep avatar nutboltu avatar patw0929 avatar superhit0 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.