title: How to find element in 2-dimensional array in underscore.js?
body: <p>Following is kind of pseudo code (simplified from real code, may not compile) </p>
  
  <pre><code>$scope.items = [
  {
      name: "Item1",
      subItems: [
          {name: "SubItem1"},
          {name: "SubItem2"}
      ]
  },
  {
      name: "Item2",
      subItems: [
          {name: "SubItem3"},
          {name: "SubItem4"},
          {name: "SubItem5"}
      ]
  },
  {
      name: "Item3",
      subItems: [
          {name: "SubItem6",
           subSubItems: [
               {name: "SubItem6-1"},
               {name: "SubItem6-2"}
           ]                          
          }
      ]
  }
  ];
  </code></pre>
  
  <p>To find a subItem, we do this</p>
  
  <pre><code>function(subItem) {
                  scope.currentItem = _.find(scope.subItems, function(sm){
                      return subItem.name === sm.name;
                  });
  }
  </code></pre>
  
  <p>Now many question is, how to search a <code>subSubItem</code> by name?</p>