title: Set HTML Background Color as JS Variable
body: <p>I want to set a variable that's been set in JavaScript as an HTML page's background.</p>
  
  <p>I'm making a Chrome new tab override, and part of it is generating a random colour hex to be the background.</p>
  
  <p>After getting this problem, I decided to test it out:</p>
  
  <pre><code>&lt;body style="background-color:colour;"&gt;
  &lt;script&gt;
  var colour = blue;
  &lt;/script&gt;
  &lt;/body&gt;
  </code></pre>
  
  <p>And yes, the tags are there. I had to delete them because stackoverflow doesn't let them show.</p>