length()
Validates that the array has exactly the specified number of items.
length(length: number, error?: StringConvertible): this;
Parameters
- length — The exact number of items required.
- error — Custom error message.
Return value
This builder, for chaining.
Related
interface Schema.ArrayBuilder static
A validation builder for array values.
