var op=document.querySelector('p'); var oP=document.createElement('p'); console.log(oP); oP.innerHTML='hello'; op.append(oP);
Why is the output here not <p></p>, but <p>hello</p>?
欢迎选择我的课程,让我们一起见证您的进步~~
This is outputting your nodes. Doesn’t the node include content?
This is the behavior of the browser to save computing resources. If the console is not opened during debugging, console.log will print the processed objects. If you open the console to view the output, console.log will print real-time Object.
This is outputting your nodes. Doesn’t the node include content?
This is the behavior of the browser to save computing resources. If the console is not opened during debugging, console.log will print the processed objects. If you open the console to view the output, console.log will print real-time Object.