DEV Community

[Comment from a deleted post]
Collapse
 
darkwiiplayer profile image
𒎏Wii 🏳️‍⚧️

type="number" is for actual numbers, which a phone number isn't. You can't add, subtract, or divide phone numbers, and they can (and often do) have meaningful leading zeroes. So at the end of the day, they are still type="text".

Collapse
 
stephanie profile image
Stephanie Handsteiner

There's input type="tel" for phone numbers, so you don't have to use text. ;)