DEV Community

Discussion on: Typical JavaScript interview exercises (explained)

Collapse
 
worsnupd profile image
Daniel Worsnup • Edited
const newHeroes = heroes.map(h => {
    return Object.assign({}, h, { name: h.name.toUpperCase() });
});