Skip to content

Commit b2a4313

Browse files
authored
Merge pull request #120 from ChoizzV2/fix_map_value_clarity
Clarified loop variable name in Map .values() example
2 parents 3e8fcd3 + 658c3ba commit b2a4313

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/cheatsheet/map.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,8 @@ You can iterate over the map values using `values()` method as in the order it w
143143
```javascript
144144
const map = new Map()
145145
map.set('name', 'Bob').set('age', 20)
146-
for (const key of map.values()) {
147-
console.log(`${key}`)
146+
for (const value of map.values()) {
147+
console.log(`${value}`)
148148
}
149149

150150
// Bob

0 commit comments

Comments
 (0)