Analyzing a Random Quote Generator_Question about what seems to be a missing closing div

Analyzing a Random Quote Generator_Question about what seems to be a missing closing div
0.0 0

#1

I am noticing that line 43 in the HTML code of the following random quote generator contains an opening div without its closing div. The code runs as intended. In what situations can we use stand-alone opening divs? Thank you for the help.

https://codepen.io/ksirgey/pen/XaNPoX?editors=1000

The code in question is <div class="ripples buttonRipples"> in

              <div class="randomBtn">
                <button class="btn btn-primary btn-lg buttonBlue" ng-click="randomQuote($event)">Random<div class="ripples buttonRipples"><span class="ripplesCircle"></span></button>
              </div><!-- End of Random Button -->

#2

I forked the pen and CodePen is now saying that I am the author. This was not intended.


#4

The answer is don’t. You should never use divs without a close. If the example has it, it is incorrect.