Now we have a problem which is that we want to lowercase a string.
Now let's imagine that we have an string like this:
And want to lowercase this string to became like this:
How to solve this problem?
The solution to this problem is easy, especially since there is a built-in function that does this called
lowercase a string using
As we said before, we can use
toLowerCase method to lowercase our string.
Let's see an example:
// String const string = "HELLO WORLD!"; // lowercase your string const lowercase = string.toLowerCase(); // Result: console.log(lowercase);
Thank you for reading
Thank you for reading my blog. 🚀