tiptap/packages/core/src/utils/capitalize.ts

4 lines
115 B
TypeScript
Raw Normal View History

2020-09-25 19:52:17 +08:00
export default function capitalize(value = ''): string {
2020-04-26 04:40:38 +08:00
return value.charAt(0).toUpperCase() + value.slice(1)
2020-09-24 06:29:05 +08:00
}