Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

alphabetize text in javascript

const alphabetize = () => {
  const newText = text
    .split(" ")
    .sort(function(a, b) {
      return a.localeCompare(b);
    })
    .join(" ")
    .toString();
  
  return newText
};
Source by www.textbotonline.com #
 
PREVIOUS NEXT
Tagged: #alphabetize #text #javascript
ADD COMMENT
Topic
Name
8+1 =