title: javascript / es6 - how to get index of first object value whos array length is greater than 0
body: <p>I have an object which is full of arrays:</p>
  
  <p><code>const errors = { name: [], date: ['invalid format'], ... }</code></p>
  
  <p>I want to find the index (or object key, if I can't get an index) of the first value in the errors object where the array length is greater than one. So in the example above, the <code>date</code> array is the first array in the object that has a length, so I would just return, ideally, <code>1</code>, or <code>date</code> if necessary.</p>
  
  <p>Anybody know the most concise / fastest way to do this in javascript / es6?</p>