DOM Manipulation Quiz

Complete this assessment with 100% score to master this chapter.

01How do you select an element with the id 'submit-btn'?

02Which method is used to listen for a click on a button?

03What does document.querySelectorAll() return?

04What property should you use to safely set the text content of an element (without risk of HTML injection)?

05In a form event listener, why would you call event.preventDefault()?