Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Object.assign()

const obj1 = {
				a: 5,
                b: 2
                }
const obj2 = Object.assign({a:6 d:7}, obj1);

console.log(obj2);
// output:  { a: 5 , b: 2, d:7} 
 
PREVIOUS NEXT
Tagged:
ADD COMMENT
Topic
Name
8+6 =