loading...

re: Simple concepts of Modern JavaScript VIEW POST

FULL DISCUSSION
 

You'll need to be careful with the order you use the spread operator. If the first object contained c it would not have been replaced. Change the order and you'll get your expected result. Also the spread operator is a shallow copy.

code of conduct - report abuse