Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I think type=number is a mistake as it is too generic. It is difficult to get proper validation, UI and error messages.

It should be split into:

type=integer so the keyboard does not allow anything besides 0-9

type=decimal so the keyboard also allows decimal dot/comma and a fixed number of decimals!

type=float which allows for scientific notation, e.g. 1.2e42




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: