In this example does the browser skip over the text “This text will not be printed” since there is a script that will replace it?
<script>
function produceSongLyric(){
var msg= 'Spent my money<br />Took my car<br/>Started telling her friends she\'s gonna be a star';
return msg;
}
</script>
<span id="mySpanName" style="color:red">This text will not be printed</span>
<script>
document.getElementById("mySpanName").innerHTML=produceSongLyric();
</script>
EDIT: Can’t you paste into jsfiddle?
No, the browser won’t skip it.
It has no way of knowing that it will be replaced until the script executes.