If the div valor0
has a value, how can I get this value in a variable to sum it up for example ??
In this example we have the valor0
div with the value 1, how do I send it to the test variable?
var teste = document.getElementById("valor0").value;
console.log(teste);
<html>
<div id="valor0"> 1 </div>
</html>