I am trying to access the value of the buttons I have created in JavaScript but it keeps showing up as undefined.
const button = document.querySelectorAll("button").value;
console.log(button);
<div class="row">
<div class="col">
<button type="button" value="7">7</button>
</div>
<div class="col">
<button type="button" value="8">8</button>
</div>
<div class="col">
<button type="button" value="9">9</button>
</div>
</div>