mjm5vp / checkpoint-02

[js, jquery]

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Checkpoint 02

Commit after each question.

Javascript: Part I

  1. Link to script.js in index.html

  2. View comments in script.js for the rest of this section's questions.

Javascript: Part II

At minimum, you should be able to complete objectives 1-4, though you should be able to also complete 5 & 6 as well using what we have learned in class so far.

  1. In index.html, link to a jQuery CDN.

  2. Link to stoplight.js in index.html

  3. Create an event listener(s) so that when you click on a light, it turns to its respective color (i.e., top light turns red). Examine style.css first and examine how the red light is being styled.

  4. If you click a light that is already on, it turns off.

  5. If you click yellow, it switches to red after two seconds.

  6. Make it so that only one light can be turned on at a time (e.g., both red and yellow cannot be on at the same time).

About

[js, jquery]


Languages

Language:JavaScript 51.7%Language:CSS 25.8%Language:HTML 22.5%