title: How to preserve order of hashmap in JavaScript?
body: <p>Java has <code>LinkedHashMap</code> but there doesn't seem to be a similar solution in JavaScript.</p>
  
  <p>Basically, I want to be able to say </p>
  
  <pre><code>var map = {};
  map['a'] = 1;
  map['b'] = 2;
  </code></pre>
  
  <p>Then when I iterate over the map, they are always in [{a:1}, {b:2}...] order.</p>