minLength static method

String? minLength(
  1. String? value,
  2. int min, {
  3. String? message,
})

Implementation

static String? minLength(String? value, int min, {String? message}) {
  if (value == null || value.length < min) {
    return message ?? 'Minimum $min characters required';
  }
  return null;
}