Migrate help command

This commit is contained in:
Ethan Lane 2021-12-02 14:09:05 +00:00
parent acedbffdad
commit 6c90307754
Signed by: Vylpes
GPG key ID: EED233CC06D12504
3 changed files with 133 additions and 150 deletions

View file

@ -0,0 +1,15 @@
export default class StringTools {
public static Capitalise(str: string): string {
const words = str.split(" ");
let result: string[] = [];
words.forEach(word => {
const firstLetter = word.substring(0, 1).toUpperCase();
const rest = word.substring(1);
result.push(firstLetter + rest);
});
return result.join(" ");
}
}