JSFiddle - React, Tailwind, and code Playground
by xkeshav
JavaScript
var peopleList = {
"1": {"Name": "Lisa", "item1": "Name of Item 1"} ,
"2": {"Name": "Marty"} ,
"3": {"Name": "Jordan", "item1":"Name of Item 1", "item2":"Name of Item 2"}
};
// add key value on 2
var MartyData = peopleList[2];
MartyData['item1'] = "Name of item 1 of Marty";
// you can check now that data added or not
alert(peopleList[2].item1);
alert(peopleList[3].Name);