Which replacement for the conditional statement on line 02 allows a developer to correctly determine that a button on page is clicked?
Given the following code:
document.body.addEventListener(‘ click ’, (event) => {
if (/* CODE REPLACEMENT HERE */) {
console.log(‘button clicked!’);
)
});
Which replacement for the conditional statement on line 02 allows a developer to correctly determine that a button on page is clicked?
A . Event.clicked
B. e.nodeTarget ==this
C. event.target.nodeName == ‘BUTTON’
D. button.addEventListener(‘click’)
Answer: C
Latest JavaScript Developer I Dumps Valid Version with 144 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund
Subscribe
Login
0 Comments
Inline Feedbacks
View all comments