step validator

Check if the value is valid step one


Using with form field
The HTML attributes are used to set the validator options via the Declarative plugin
NameHTML attributeTypeDescription
baseValuedata-fv-step___base-valueFloatThe base value, default to 0
messagedata-fv-step___messageStringThe error message
stepdata-fv-step___stepFloatThe step, default to 1
Using with ES6 module
// You might need to change the importing path
import step from 'formvalidation/dist/es6/validators/step';
const result = step().validate({
value: ...,
options: {
baseValue: ...,
message: ...,
step: ...,
result is an object of
valid: true or false,
message: The error message


  • Fixed an issue that the step option isn't passed to the placeholder message