title: How do I maintain linebreaks and indenting when submitting HTML to a server?
body: <p>I have a HTML <code>&lt;textarea&gt;</code> that I am using to paste HTML into. 
  The contents of the textarea are then being submitted to a firestore server. </p>
  
  <p>I then render the HTML into:<br>
  <code>&lt;p white-space: pre-line;&gt;HERE&lt;p&gt;</code></p>
  
  <p>This approach will maintain the line breaks <strong>but not</strong> the indenting.<br><br>
  This:</p>
  
  <pre><code>&lt;div&gt;
    &lt;table&gt;
      &lt;tr&gt;
        &lt;td&gt;Test code&lt;/td&gt;
      &lt;/tr&gt;
    &lt;/table&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>Becomes this:</p>
  
  <pre><code>&lt;div&gt;
  &lt;table&gt;
  &lt;tr&gt;
  &lt;td&gt;Test code&lt;/td&gt;
  &lt;/tr&gt;
  &lt;/table&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>How would I go about maintaining the indenting?</p>