var myJSON = {
list1 : [ 1, 2 ],
list2 : [ a, b ],
list3 : [ { key1 : value1 }, { key2 : value2 } ],
not_a_list : 11
};
How do I dynamically build this JSON structure in javascript? Google tells me to use use some push command, but I've only found specific cases. So what do I write to enter data to listX and not_a_list. Appending as well as creating a new list. The whole procedure begninning with:
var myJSON = {};