You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For example, from my webform, I might have the country calling code "+1" and the national number "202456111". What is the expected way to go from that to a parsed phonenumber?
The Java version of libphonenumber allows creation of a number like this:
But for using nyaruka/phonenumbers I don't see any pattern for creating a number from a separate country code and national number. There aren't any setters. Checking GitHub, I'm seeing code that basically concatenates the two strings together, but this involves some trimming and adding a + if not present.
Am I missing the intended way to create a phonenumber from countryCode + nationalNumber? Is it to convert country code to region instead of setting the values directly, e.g.
For example, from my webform, I might have the country calling code "+1" and the national number "202456111". What is the expected way to go from that to a parsed phonenumber?
The Java version of libphonenumber allows creation of a number like this:
But for using
nyaruka/phonenumbers
I don't see any pattern for creating a number from a separate country code and national number. There aren't any setters. Checking GitHub, I'm seeing code that basically concatenates the two strings together, but this involves some trimming and adding a + if not present.Am I missing the intended way to create a phonenumber from countryCode + nationalNumber? Is it to convert country code to region instead of setting the values directly, e.g.
In other words, shouldn't there be something like the SetCountryCode and SetNationalNumber in this library?
The text was updated successfully, but these errors were encountered: