Filterfunction using array instead unordered list
<p>I need to filter a huge list of items in Javascript by certain strings users can enter in an input field.</p>

<p>Currently I set it up in an unordered list, all of which items are hidden on page load and displayed as needed while the user types. The user then clicks on one item and a value gets stored in a hidden field.</p>

<p>However I was wondering if it is better for low-end devices and mobile devices to use a javascript array instead of building a 3000 item list in the HTML DOM.</p>

<p>like: <code>var gkz = [[123,test],[345,test2],[867,banana]];</code></p>

<p>instead of:</p>

<p><code>&lt;ul&gt;
&lt;li&gt;item1&lt;/li&gt;
...
&lt;li&gt;item 3000&lt;/li&gt;
&lt;/ul&gt;</code></p>

<p>Could someone show me how to create the functionality of this fiddle
<a href="https://jsfiddle.net/0cgbcy35/" rel="nofollow">https://jsfiddle.net/0cgbcy35/</a> with an array as source of items instead of a list?</p>