capitalize static method

String? capitalize(
  1. String value
)

Capitalize each word inside string Example: your name => Your Name, your name => Your name

Implementation

static String? capitalize(String value) {
  if (isNull(value)) {
    return null;
  }
  if (isBlank(value)!) {
    return value;
  }
  return value.split(' ').map(capitalizeFirst).join(' ');
}