is there a library/service class available to validate international mobile numbers individually? E.g. Singapore mobile number must have 8 digits, China 11 digits, etc. Currently I'm using ng4-intl-phone in reactive form format to allow user to input their mobile numbers.
The validations should appear according to each country and not a general check for international phone numbers like the number is from 3 to 14 digits (It was what I was using previously).
Appreciate your help!
UPDATE
I used https://www.npmjs.com/package/ngx-international-phone-number for the time being instead. I'll still leave those answers below if anyone needs to use them for reference!
I have used libphonenumber-js in my angular 6 project and it works perfectly fine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With