code: function assignDepthsAt(i) {
      var eles = depths[i];
  
      for (var j = 0; j < eles.length; j++) {
        var _ele2 = eles[j];
  
        if (_ele2 == null) {
          eles.splice(j, 1);
          j--;
          continue;
        }
  
        setInfo(_ele2, {
          depth: i,
          index: j
        });
      }
    }
docs: assign the nodes a depth and index