ExamVeda
Login
Home
This question belongs to Javascript Classes And Modules
Classes and Modules
?

What is the procedure to add methods to HTMLElement so that they will be inherited by the objects that represent the HTML tags in the current document?

Answer & Solution
Correct Answer: Option B
It is implementation-dependent whether classes defined by the host environment (such as the web browser) can be augmented using Object.prototype. In many web browsers, for example, you can add methods to HTMLElement.prototype and those methods will be inherited by the objects that represent the HTML tags in the current document.
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.