Created
May 4, 2021 12:19
-
-
Save pecuchet/de6d22b5778c7627d23a1102119b466c to your computer and use it in GitHub Desktop.
Capitalize a string in js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const capitalize = str => str.charAt(0).toUpperCase() + str.slice(1); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment