title: Javascript - Count array objects that have a value
body: <p>I'm getting an array returned to me and I need to count the rows that have a value in them</p>
  
  <p>I've tried to call arr.length but that gives me the total length of the array</p>
  
  <pre><code>var arr = [
    { id: '1', '': '' },
    { id: '2', '': '' },
    { id: '3', '': '' },
    { id: '4', '': '' },
    { id: '', '': '' },
    { id: '', '': '' },
    { id: '', '': '' }
  ]
  </code></pre>
  
  <p>The result should be 4.</p>