3 ms·
Really neat! Any plans on open sourcing the formatting library? It's a good functionality, but (at least for me) would mainly be useful for view-layer on-the-
by sandstrom 12y ago
Really neat!
Any plans on open sourcing the formatting library?
It's a good functionality, but (at least for me) would mainly be useful for view-layer on-the-fly formatting, and we wouldn't use an remote API request for that.
Sort of like Strip's jQuery.payment[1], it would be a simple and clever marketing trick. People searching for a phone number formatting library are just the people you want to sell your services to.
EDIT: just found libphonenumber, which does local formatting[2]
[1] https://github.com/stripe/jquery.payment https://github.com/stripe/jquery.payment
[2] https://github.com/googlei18n/libphonenumber https://github.com/googlei18n/libphonenumber
- RobSpectre 12y agolibphonenumber is definitely the jam for offline formatting - we use it all the time.
- bombtrack 12y agoI would agree that libphonenumber is the go-to for what you want to do. The JS build process for it is... involved, but you can find pre-built versions of it for Node, UMD, etc.
- fxx2 12y agoStripe actually released a mobile phone number formatting library. https://github.com/stripe/jquery.mobilePhoneNumber https://github.com/stripe/jquery.mobilePhoneNumber