title: How to recursively search the DOM and return first element that has a specified class
body: <p>For example - return the 1st element that has class = "title". 
  The result in this case should be <em>div3.1</em>
  Should only use vanilla JS.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;body&gt;
          &lt;div class="container"&gt;
              &lt;div class="abc"&gt; div1&lt;/div&gt;
              &lt;div class="abc"&gt; div2
                  &lt;div class="abc"&gt;div2.1
                      &lt;a href="http://"&gt;&lt;/a&gt;
                      &lt;p&gt;Lorem ipsum dolor sit amet consectetur adipisicing elit. Illo, ipsum?&lt;/p&gt;
                  &lt;/div&gt;
                  &lt;div class="abc"&gt;div2.2&lt;/div&gt;
                  &lt;div class="abc"&gt;div2.3&lt;/div&gt;
              &lt;/div&gt;
              &lt;div class="abc"&gt; div3
                  &lt;div class="title"&gt;div3.1&lt;/div&gt;
                  &lt;div class="title"&gt;div3.2
                      &lt;img src="" alt=""&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
      &lt;/body&gt;</code></pre>
  </div>
  </div>
  </p>