== .toTitleCase ==

.toTitleCase()

Converts each word in a string to Title Case.
Usage
String = String.toTitleCase ()
Member of:
[[mdn>Web/JavaScript/Reference/Global_Objects/String|String]]
Returns:
[[mdn>Web/JavaScript/Reference/Global_Objects/String|String]]
===== Examples ===== Simple examples: "lorem ipsum dolor sit amet".toTitleCase(); // result: "Lorem Ipsum Dolor Sit Amet" "LATIN CAPITAL LETTER J".toTitleCase(); // result: "Latin Capital Letter J" This also works for non-Latin scripts, as long as there are actually letter cases in that script: "οἱ δὲ φοίνιϰες οὗτοι οἱ σὺν κάδμῳ ἀπιϰόμενοι".toTitleCase(); // result: "Οἱ Δὲ Φοίνιϰες Οὗτοι Οἱ Σὺν Κάδμῳ Ἀπιϰόμενοι" "bсички хора се раждат свободни".toTitleCase(); // result: "Bсички Хора Се Раждат Свободни" ===== Relevant JavaScript methods ===== * [[mdn>Web/JavaScript/Reference/Global_Objects/String/toUpperCase|String.prototype.toUpperCase()]] on MDN. * [[mdn>Web/JavaScript/Reference/Global_Objects/String/toLowerCase|String.prototype.toLowerCase()]] on MDN.