Re: Datalist pollute the DOM

1. Enable gzip transfer encoding.
2. Use AJAX and send a JSON request for the list you want, formatted as a string. Tthen just break it apart and programmatically add the items to the list. 




________________________________
 From: Fred . <eldmannen@gmail.com>
To: public-html-comments@w3.org 
Sent: Thursday, August 30, 2012 10:28 AM
Subject: Datalist pollute the DOM
 
So I have to do <option>Foo</option>
Repeat that 1000 times, and I have massively polluted my DOM with elements.
Also I want transfer Foo which is 3 bytes, but then I have to transfer
opening and closing tags and that takes lots of bandwidth when you
multiply that by 1000.

You should be able make the client fetch the datalist from the server.
And the server send a CSV or something "Alice,Bob,Clare,Dave,Eve,..."

Received on Thursday, 30 August 2012 14:43:53 UTC