I am using <input type=number>
where I place values using Javascript. I'd like to format these numbers to have always one decimal. Chrome stubbornly strips out of trailing zero from the numbers if they have any e.g. 1.0 -> 1.
Apparently I should set pattern
attribute of the control. However I am not sure what kind of values Chrome accepts here and what would be the correct pattern for formatting numbers.