title: How to extract text from html String
body: <p>I am trying to extract text from an html string but, it is not working as expected.</p>
  <p>The html string I have is,</p>
  <pre><code>&lt;div data-content-type=&quot;html&quot; data-appearance=&quot;default&quot; data-element=&quot;main&quot;&gt;&amp;lt;p&amp;gt;The Angelina Tank Dress is simple yet sophisticated. This dress can be thrown over a swimsuit for last minute lunch plans or belted for dinner on the patio. The high-low hemline gives it the perfect amount of swing. &amp;lt;/p&amp;gt;&amp;lt;p&amp;gt;Features:&amp;lt;/p&amp;gt;&amp;lt;ul&amp;gt;&amp;lt;li&amp;gt;Scoopneck&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Sleeveless&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Hits below the knee&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Longer back hemline&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;Machine wash, tumble dry low&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;&lt;/div&gt;
  </code></pre>
  <p>There is a description text and text inside the ul li elements. How could I extract all of that text separately. For example, extract the description text separately and the text inside li elements separately.</p>
  <p>I tried</p>
  <pre><code> const productDescription = productDetails.description.replace(/&lt;div&gt;|&lt;\/div&gt;|&lt;ul&gt;|&lt;li&gt;/g, &quot;&quot;).trim().split(&quot;Features:&quot;);
      
  </code></pre>
  <p>I would like the text to be</p>
  <p>The Angelina Tank Dress is simple yet sophisticated. This dress can be thrown over a swimsuit for last minute lunch plans or belted for dinner on the patio. The high-low hemline gives it the perfect amount of swing.</p>
  <p>Scoopneck
  Sleeveless
  Hits below the knee
  Longer back hemline
  Machine wash, tumble dry low</p>