PasswordRequirement.maxLength constructor

PasswordRequirement.maxLength(
  1. int length
)

Creates a PasswordRequirement for a maximum length.

Implementation

factory PasswordRequirement.maxLength(int length) => PasswordRequirement(
  description: 'At most $length characters',
  validator: (password) => password.length <= length,
);