Rock Paper Scissors
A simple game against the computer using basic JavaScript logic and randomness.
JavaScript
HTML
CSS
How it was implemented
Click handlers map to a small rules engine that compares choices and updates the scoreboard. The UI is intentionally minimal and clear.
What I learned
-
Targeted DOM access with
document.getElementById(...)for fast, explicit lookups. -
innerHTMLvstextContent: rendering HTML markup vs safely setting plain text. -
Timer control using
setInterval(...)to drive updates andclearInterval(...)to stop them cleanly.