title: Array methods for DOM HTML?
body: <p>I need to make an <code>array</code> from <code>li</code> tags. The array must include their inner <code>texts</code>. Eache index in array with each inner <code>texts</code> of <code>li</code> tags.</p>
  
  <p>I'm trying to call the array method slice by <code>Array.prototype.slice()</code>. But probably I making some wrong...</p>
  
  <p>The result must be like: </p>
  
  <pre><code>arr = ["Animals", "0_", .... , "fish__"]
  </code></pre>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>var bodyd = document.getElementsByTagName('li');
  for (var i = 0; i &lt; bodyd.length; i++) {
    bodyd = Array.prototype.slice.call(bodyd, 1);
    console.log(bodyd);
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;ul&gt;
    &lt;li&gt;Animals
      &lt;ul&gt;
        &lt;li&gt;0_
          &lt;ul&gt;
            &lt;li&gt;1__&lt;/li&gt;
            &lt;li&gt;2__&lt;/li&gt;
            &lt;li&gt;3__&lt;/li&gt;
            &lt;li&gt;4__&lt;/li&gt;
          &lt;/ul&gt;
        &lt;/li&gt;
        &lt;li&gt;Other_
          &lt;ul&gt;
            &lt;li&gt;Slis__&lt;/li&gt;
            &lt;li&gt;Bird__&lt;/li&gt;
            &lt;li&gt;Repti__&lt;/li&gt;
          &lt;/ul&gt;
        &lt;/li&gt;
      &lt;/ul&gt;
    &lt;/li&gt;
    &lt;li&gt;Fish
      &lt;ul&gt;
        &lt;li&gt;Aqua
          &lt;ul&gt;
            &lt;li&gt;Aqua__&lt;/li&gt;
            &lt;li&gt;Aqua__&lt;/li&gt;
          &lt;/ul&gt;
        &lt;/li&gt;
        &lt;li&gt;fish_
          &lt;ul&gt;
            &lt;li&gt;fish__&lt;/li&gt;
          &lt;/ul&gt;
        &lt;/li&gt;
      &lt;/ul&gt;
    &lt;/li&gt;
  &lt;/ul&gt;</code></pre>
  </div>
  </div>
  </p>