title: How to display a string javascript in HTML
body: <p>In my HTML file I have a div with id="list".
  Now I want to display a string from my javascript in my html. page. but nothning
  happen. In my html file, i've imported the srcipt file. Here's how it looks in my script file:</p>
  
  <pre><code>var namesArray = ["lars", "bo", "ib", "peter", "jan", "frederik"];
  
  var list = namesArray.map(name=&gt;"&lt;li&gt;"+name+"&lt;/li&gt;");
  var listAsStr ="&lt;ul&gt;" + list.join("") + "&lt;ul&gt;";
  document.getElementById("list").innerHTML = listAsStr;
  </code></pre>