Nodejs Utililty Methods String Title Case

List of utility methods to do String Title Case

Description

The list of methods to do String Title Case are organized into topic(s).

Method

toTitleCasetoTitleCase()
String.prototype.toTitleCase = function toTitleCase() {
    return this.replace(/\w\S*/g, function(txt){return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();});
};