Created
December 15, 2025 15:47
-
-
Save av1v3k/11c5497096e00b9d490e707ca48aaabf to your computer and use it in GitHub Desktop.
Use Map in JS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let m = new Map<string, number>([ | |
| ['address', 500], | |
| ['age', 25], | |
| ]); | |
| m.set('street', 400); | |
| console.log(m.get('address')) | |
| console.log(m) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment