Skip to content

number

Field validator

All field validators

The value must be a whole number.

Written as
"Validators": [{ "Type": "number" }]
In Liquid
{{ number_validator }} — the typed object a template reads for this rule.
Use with
text

Properties

Accepted in addition to the shared properties every definition carries.

Property Required Description
Message — Text shown when the value fails this check.

Notes

Adding this also changes how the comparison rules read the field: gt, gte, lt, lte, and eq then treat the value as a number rather than a string. Without it, "10" sorts below "9".