Deep copy using spread

Report a typo

Make a deep copy of the object below (man) using the spread operator. Don't output or return anything, complete the shallowCopy definition.

Write a program in JavaScript
const man = { name: 'John', mother: { name: 'Bella'} };
const shallowCopy = //write your code here
___

Create a free account to access the full topic