📜  循环通过 json 对象 jquery - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:39.737000             🧑  作者: Mango

代码示例4
//https://code.jquery.com/jquery-3.5.0.js

var scores = '{ "first": { "score": 660 }, "second": { "score": 330 } }';

var objkeys = $.parseJSON(scores);  
          
$.each(objkeys, function(key, value) {
    $.each(value, function(key, value){
        console.log(value);                        
    });
});