Below is the html and js I have for my progress bar:
But my console is telling me the value of the variable dragonHealth is null when it should be 100 as initialized. From what I have found, the value should be a floating point variable so why is it coming out as null? Not too familiar with this progress tag btw. Thanks for the help. Btw, the health ID in my css is just a blank one created just to reference it in js.
JS
var dragonHealth = document.getElementById("health").value;
html
<progress id="health" value="100" max="100"></progress>