misskey/src/prelude/string.ts

4 lines
112 B
TypeScript
Raw Normal View History

2018-09-07 03:22:55 +09:00
export function capitalize(s: string): string {
return s.charAt(0).toUpperCase() + s.slice(1).toLowerCase();
}