title: How to iterate over Object's property-value pairs?
body: <p>I have a structure like this:</p>
  <pre><code>var myMap = {
      partnr1: ['modelA', 'modelB', 'modelC'],
      partnr2: ['modelA', 'modelB', 'modelC']
  };
  </code></pre>
  <p>I am going to iterate through each of the elements (partnr) with their associatives (models).</p>
  <p>I am trying a double <code>$each()</code> iteration in order to achieve this, but nothing happens:</p>
  <pre><code>$.each(myMap, function (i, val) {
      $.each(i, function (innerKey, innerValue) {
  
          setTimeout(function () {
              $('#variant').fadeOut(&quot;slow&quot;, function () {
                  $(this).text(innerKey + &quot;-&quot; + innerValue).fadeIn(&quot;slow&quot;);
  
              });
  
          }, i * 6000);
  
      });
  });
  </code></pre>
  <p>The effect with fading in and out that I am trying to achieve is working fine when using a single value array (<code>Object</code>), but not when I need to have more than one value for each key like here.</p>
  <p>How to accomplish this iteration successfully? Are there other ways than using an <code>Object</code> that would be better in this case?</p>