Number

A number input field with validation

The number field generates an HTML 5 number input, which is great when you need a comfortable way to enter any numeric values. The number field also comes with built-in validation for numeric data.

Example

fields:
  number:
    label: Number
    type: number

Decimals

Decimals can be used by adding the step option.

fields:
  price:
    label: Price
    type: number
    step: .01

Minimum and maximum value

The min and max options define which numbers can be selected with the browser-specific up/down arrows and are also used to validate the input.

fields:
  temperature:
    label: Temperature
    type: number
    min: -50
    max: 250

Result

Screenshot Number