📜  firebase 迭代对象 - Javascript 代码示例

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

代码示例1
firebase.database().ref("profile/user_id").on('value', function(snap){

   snap.forEach(function(childNodes){

      //This loop iterates over children of user_id
      //childNodes.key is key of the children of userid such as (20170710)
      //childNodes.val().name;
      //childNodes.val().time;
      //childNodes.val().rest_time;
      //childNodes.val().interval_time;


  });
});