toCapitalizedWord method

String toCapitalizedWord()

Implementation

String toCapitalizedWord() => 1 < length
    ? substring(0, 1).toUpperCase() + substring(1).toLowerCase()
    : toUpperCase();