"Class" : "5", "person" : "Abhinandan", "price" : "20", "time" : "20:45/12:35"}',
'{"number" : "shwin", "Class" : "1", "person" : "bhinandan", "price" : "50", "time" : "20:15/14:35"}',
'{"number" : "hwin", "Class" : "2", "person" : "hinandan", "price" : "30", "time" : "22:15/14:35"}',
'{"number" : "win", "Class" : "3", "person" : "inandan", "price" : "40", "time" : "10:45/15:35"}',
'{"number" : "in", "Class" : "4", "person" : "nandan", "price" : "10", "time" : "12:45/10:35"}',
'{"number" : "shwin", "Class" : "1", "person" : "bhinandan", "price" : "50", "time" : "20:15/14:35"}',
'{"number" : "hwin", "Class" : "2", "person" : "hinandan", "price" : "30", "time" : "22:15/14:35"}',
'{"number" : "win", "Class" : "3", "person" : "inandan", "price" : "40", "time" : "10:45/15:35"}',
'{"number" : "in", "Class" : "4", "person" : "nandan", "price" : "10", "time" : "12:45/10:35"}'
];
var tables = rooms.map(JSON.parse);
как перебрать свойства массива обьектов tables?
У тебя же строки а не объекты
rooms.map(value => JSON.parse(value))
Обсуждают сегодня