Sign In
Curriculum
Listen for Click
Mark as Completed
Listen for Click
Write a function called
listenForClick
that adds a click event listener to a given element and logs "Button was clicked!" to the console when the button is clicked.
Click to go back
Click to go forward
Refresh preview
Console
Submit
Solution
00:00
Previous Lesson
Next Lesson