title: Create an HTML list from JSON
body: <p>I have an array of objects:</p>
  
  <p><a href="https://i.stack.imgur.com/M8xS2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/M8xS2.png" alt="enter image description here"></a></p>
  
  <p>I have a div: </p>
  
  <pre><code>&lt;div class="col-lg-12" id="list-puntate"&gt;
    &lt;!-- Insert my list here --&gt;                              
  &lt;/div&gt;
  </code></pre>
  
  <p>JS</p>
  
  <pre><code>var listDiv = document.getElementById('list-puntate');
  var ul = document.createElement('ul');
  ul.appendChild(listDiv);
  for(var i = 0; i &lt; data.list.length; ++i) {
    var li = document.createElement('li');
    li.appendChild(data.list[i].puntata);
    ul.appendChild(li);                                 
  }
  </code></pre>
  
  <p>I would like to have a result like this: </p>
  
  <pre><code>&lt;div class="col-lg-12" id="list-puntate"&gt;
    &lt;ul&gt;
      &lt;li&gt;values of data.list[i].puntata&lt;/li&gt;
      &lt;li&gt;...&lt;/li&gt;
    &lt;/ul&gt;                              
  &lt;/div&gt;
  </code></pre>