Click here to play: DEMO
JavaScript Project part of The Odin Project curriculum. Part One and Part Two
I decided to use this project to put all my current knowledge to practice - HTML, CSS, and JavaScript(DOM manipulation). I had to re-work my HTML structure a couple times, until I was satisfied with the design of the page. The functionality that I created with javascript was added bit by bit.
I had a bit of a struggle figuring out how to remove a css transition that I added for a 'click' event. After researching I was able to figure it out. I added an event listener for 'transitionend', which would remove the css class.
- The game is played against the computer.
- Player chooses rock, paper or scissors and both - the computer and the player choices will be highlighted.
- The score is registered on the top of the page.
- There is a log where the player can see the results for past rounds.
- The first to reach 5 points win the game.
- A button to restart the game will appear when the game is over.