title: Visual Studio Code autocomplete/IntelliSense not working properly for JavaScript
body: <p><a href="https://i.stack.imgur.com/Wok4j.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Wok4j.png" alt="Image of vscode autocomplete" /></a><br />
  It's not displaying the properties of an array like length etc.</p>
  <p>I'm not sure if this is a problem or this is expected behavior of VScode's autocomplete/IntelliSense.</p>
  <p>Do I need to install any extensions to make it work?</p>
  <p><strong>Edit:</strong><br />
  On adding <code>var</code> or <code>let</code> before <code>arr</code> the autocomplete works fine normally but inside a function it doesn't work.<br />
  <a href="https://i.stack.imgur.com/yVHHh.png" rel="noreferrer"><img src="https://i.stack.imgur.com/yVHHh.png" alt="autocomplete inside a function" /></a></p>