javascript simple way to change variable to have capital letter code example
Example: javascript name capitalization
function capitalizeName(name) {
return name.replace(/\b(\w)/g, s => s.toUpperCase());
}
function capitalizeName(name) {
return name.replace(/\b(\w)/g, s => s.toUpperCase());
}