mirror of
https://github.com/nx-bat/discordbot-ng.git
synced 2026-11-11 07:13:37 -05:00
6 lines
180 B
TypeScript
6 lines
180 B
TypeScript
export function humanizeCapitalization(str: string): string {
|
|
return str.toLowerCase()
|
|
.split(' ')
|
|
.map(s => s.charAt(0).toUpperCase() + s.substring(1))
|
|
.join(' ');
|
|
} |