title: typescript Property 'type' does not exist on type 'never'
body: <p>I have the typescript error <code>typescript Property 'type' does not exist on type 'never'</code> in the code</p>
  
  <pre><code>export const getSomething = (actionLog: [] | undefined) =&gt; {
    console.info(actionLog[length - 1].type)
  }
  </code></pre>
  
  <p>What is the issue?</p>