validateLengthOf
can.Map.validations.static.validateLengthOf
observe.validateLengthOf(attrNames, min, max, options)
Validates that the specified attributes' lengths are in the given range.
init : function(){
this.validateInclusionOf(["suffix"],3,5)
}
Parameters
-
attrNames
{Array<String>}
Attribute name(s) to to validate
-
min
{Number}
Minimum length (inclusive)
-
max
{Number}
Maximum length (inclusive)
-
options
{Object}
OptionalOptions for the validations. Valid options include 'message' and 'testIf'.