toCapitalizeFirst property

String get toCapitalizeFirst

Implementation

String get toCapitalizeFirst {
  if (isEmpty || length < 2) {
    return this;
  }
  return this[0].toUpperCase() + substring(1).toLowerCase();
}