The property event.target gives access to the _________ that triggered the event.
- element
- object
- source
- target
The event.target property in JavaScript gives access to the element that triggered the event. It's especially useful in event delegation and can be used to identify which specific element was interacted with in a group of similar elements.
Loading...
Related Quiz
- Consider a function that fetches user information from an API. If the API call fails, you want to log an error message and then continue the execution of the function without throwing an exception to the outer scope. Which Promise method should you use to achieve this?
- Using the new keyword invokes a _______ that creates a new object.
- A function declaration is hoisted to the top of the ________ in which it was defined.
- Which design principle is violated if a superclass is aware of its subclasses?
- What does a Promise represent in JavaScript?