Answers for "how to merge two dictionaries in javascript with ..."

1

javascript combine dictionaries

var a = {};
a['fruit'] = "apple";

var b = {};
b['vegetable'] = "carrot";

var food = Object.assign({}, a, b);

console.log(food);
Posted by: Guest on October-16-2020

Code answers related to "how to merge two dictionaries in javascript with ..."

Code answers related to "Javascript"

Browse Popular Code Answers by Language