Map getOrInsert()
The getOrInsert() and getOrInsertComputed() methods of Map objects get a value, setting and getting a default value if needed.
Status
Limited availability
MDN documentation
Browser support
- Chrome ❌
- Chrome Android ❌
- Edge ❌
- Firefox 144 Released on 2025-10-14
- Firefox for Android 144 Released on 2025-10-14
- Safari ❌
- Safari on iOS ❌
Developer signals
Votes: 0
If you want this feature to be available in all browsers, vote for it by adding a thumbs up reaction (👍) to this GitHub issue, and leave a comment with more information.
View as JSON | Edit this feature | Report an issue | Web-features entry: source, dist