+ 4
Please , i went details explanation about .innerHTML in js.
Decument.innerHTML
2 Answers
+ 17
Here you can find some information about it with examples:
https://developer.mozilla.org/en-US/docs/Web/API/Element/innerHTML
+ 2
It changes an elements text inside. Example:
HTML:
<div id = "d"></div>
JS:
document.getElementById("d").innerHTML = "changed"
HTML after JS runs:
<div id = "d">changed</div>