Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js caps first letter

// Oneliner, get first character, replace it with first character in upper case
string.replace(string[0], string[0].toUpperCase())
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #js #caps #letter
ADD COMMENT
Topic
Name
5+2 =