Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
let obj1 = {'a':'1'};
let obj2 = Object.assign({}, obj1);
obj1.b = '2';
console.log(obj2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment