title: firebase and node js : event when value added to the list
body: <p>I am using firebase on node js.</p>
  
  <p>below is my data model</p>
  
  <pre><code>"sList" : {
      "-K_KxnexiRMvC81bTEVH" : {
            "description" : "sdf",
            "name" : "sdf",
            "users" : [ "-K_Kxnf9XBnClTgFv67z", "-K_KvlWOiNCOBDL-Vl3y" ]
          },
      "-K_KxnexiRMvC81asdabTEVHas" : {
            "description" : "sdf",
            "name" : "pdsff",
            "users" : [ "-K_Kxnf9XBnClTgasv67z", "-K_KvlWOiNCsadOBDL-Vl3y" ]
          },
  }
  </code></pre>
  
  <p>unique id's will be added to the users array in each document.</p>
  
  <p>How can i add an event listener over all the users array in each document whenever the unique id is added</p>
  
  <p>Below code i have tried, but not working</p>
  
  <pre><code>var listRef = firebaseAdmin.database().ref('/sList');
  
  listRef.on('child_changed', function(dataSnapshot) { 
      const msg= dataSnapshot.val();
      const key= dataSnapshot.key();
      var userRef = listRef.child();
      userRef.on('child_changed', function(childDataSnapshot) {
          const val=childDataSnapshot.val();
       });
  })
  </code></pre>