Challenge 1 of 3
Click listener
Instructions
Add a `click` listener to `#click-me` that sets `clicked` to true. Tests will click the button.
Editor
IntelliSense on
let clicked = false; // Write your code below
Module 4 of 5
Attach listeners and react to clicks, input, and submit.
JavaScript DOM · 0/3 completed · scroll down for every challenge
Challenge 1 of 3
Add a `click` listener to `#click-me` that sets `clicked` to true. Tests will click the button.
Editor
IntelliSense on
let clicked = false; // Write your code below
Challenge 2 of 3 · Input listener
Challenge 2 of 3
Listen for `input` on `#name` and copy its value into `typed`.
Editor
IntelliSense on
let typed = ""; // Write your code below
Challenge 3 of 3 · Prevent submit
Challenge 3 of 3
Listen for `submit` on `#signup`, call `preventDefault()`, and set `blocked` to true.
Editor
IntelliSense on
let blocked = false; // Write your code below
Next module