phone_number v0.2.3 PhoneNumber View Source

Library for validating international phone numbers. Based on Google's libphonenumber.

Link to this section Summary

Link to this section Functions

Link to this function

parse(phone) View Source
parse(String.t()) :: %PhoneNumber.Phone{
  country: term(),
  original_number: term(),
  valid: term()
}

parse phone number

Examples

iex> phone = PhoneNumber.parse("381601234567")
...>
iex> phone.valid
true
Link to this function

possible_countries(phone) View Source