79081006

Date: 2024-10-12 12:41:29
Score: 1
Natty:
Report link

Found a more compact solution

const output = value.map((v, index) => {return {...v, ...list[index]}})

the ... modifier strips objects of their outer brackets so like so:

key:value == ...{key:value}
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Sato