How can you create a node for comment in JavaScript?

How can you create a node for comment in JavaScript?
A. comment()
B. createComment()
C. comm()
D. create()
 
Answer: b
Explanation: The comment node can be created using the method Comment createComment(string data). The createComment() method creates a Comment node with the specified text.
 

Tìm kiếm

Back
Top