Checks if length of value is less than or equal to the provided length.
const passwordMaxLength = maxLength(16);passwordMaxLength("aaaaaaaaaaaaaaaaa"); // Error: maxLengthpasswordMaxLength("Test123456"); // passes Copy
const passwordMaxLength = maxLength(16);passwordMaxLength("aaaaaaaaaaaaaaaaa"); // Error: maxLengthpasswordMaxLength("Test123456"); // passes
Length used in the comparison.
Checks if length of value is less than or equal to the provided length.
Example