registerValidator()

Register a validator

It is used when you want to use a custom validator.

* presents a required parameter

  • name * — The name of validator
  • func * — The validator function

More examples