toLowerCase Examples¶
/*The general syntax for this method is:
stringName.toLowerCase();
This method returns a copy of stringName with all uppercase letters
replaced by their lowercase counterparts. It leaves non-alphabetic
characters unchanged.*/
"LaunchCode".toLowerCase();
//launchcode
//
/*This program standardizes an email address by converting it to all
lowercase characters.*/
let input = "[email protected]";
let email = input.toLowerCase();
console.log(email);
//[email protected]