Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js get initials from name

const fullName = nameString.split(' ');
const initials = fullName.shift().charAt(0) + fullName.pop().charAt(0);
return initials.toUpperCase();
 
PREVIOUS NEXT
Tagged: #js #initials
ADD COMMENT
Topic
Name
4+3 =