File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed
Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,7 @@ To install caffeinated-strings, run the following command:
2727| ` ===, >, < ` | ` compareBeans ` | Compares two strings (like comparing coffee beans for quality). |
2828| ` .indexOf() ` | ` findFirstSip ` | Finds the first occurrence of a ** character** in a string (like the first sip of coffee). |
2929| ` .indexOf() ` | ` findFlavor ` | Finds the first occurrence of a ** substring** inside a string (like detecting flavors in coffee). |
30+ | ` .toLowerCase() ` | ` coolDown ` | Transforms the string to lowercase (like cooling down a cup of coffee). |
3031| ` .toUpperCase() ` | ` froth ` | Transforms the string to uppercase (like frothing the milk to create a creamy top). |
3132
3233## 🔧 Usage
@@ -99,7 +100,16 @@ let drink = "cappuccino";
99100console .log (findFlavor (drink, " cc" )); // "ccuccino"
100101```
101102
102- 8 . ` froth(str) `
103+ 8 . ` coolDown(str) `
104+ Transforms the string to lowercase (like cooling down a cup of coffee).
105+ Returns the input in lowercase as ` string ` :
106+
107+ ``` js
108+ let drink = " ESPRESSO" ;
109+ console .log (froth (drink)); // "espresso"
110+ ```
111+
112+ 9 . ` froth(str) `
103113 Transforms the string to uppercase (like frothing the milk to create a creamy top).
104114 Returns the input in uppercase as ` string ` :
105115
You can’t perform that action at this time.
0 commit comments