I'm trying to pull a link from the following html. There's lots of bits of HTML like this one in an array.
tweets[0] is:
var tweets = Array.from(document.querySelectorAll("[class ^= AdaptiveMedia-ph]"));
console.log(tweets);
<div class="AdaptiveMedia-photoContainer js-adaptive-photo " data-image-url="https://pbs.twimg.com/media/DfFmgY6WAAAh0sG.jpg" data-element-context="platform_photo_card" style="background-color:rgba(51,64,18,1.0);" data-dominant-color="[51,64,18]">
<img data-aria-label-part="" src="https://pbs.twimg.com/media/DfFmgY6WAAAh0sG.jpg" alt="A tree" style="width: 100%; top: -0px;">
</div>
How do I go about actually pulling the link in "src" and the alt text from "alt" from the HTML text? Thanks in advance!
srcandaltfrom the inner<img>tag?