Assuming the html below:
<div id="contentWrapper">
<h2>Title<br>Page</h2>
<div>
<h4>Subtitle Text<br>
March 26, 2018</h4>
<p><iframe src="https://www.youtube.com/embed/ID" allow="autoplay" allowfullscreen="" width="760" height="428" frameborder="0"></iframe></p>
</div>
<p>This is text that adds meaningful value to the website. It is what the user reads</p>
<p>If you have read up to this part I'm actually impressed.</p>
<p><strong>* * * * * * *</strong></p>
</div>
How can I get every immediate child tag within the contentWrapper as an array that would look like this:
[h2, div, p, p, p]
Notice I don't want the children of children, just the first child.
I thought about using the querySelectorAll() method, but from what I can tell this requires a css selector as a parameter. I won't know ahead of time what types of tags are in this div so I can't "pre-feed" it selectors.