The goal of this project was to create an application that allows the user to play Tic Tac Toe. The user can start out as one character and then once that character picks a spot on the grid the next character can go. Once each round is over the winner is displayed at the top and then their win total goes up on that characters side. After the round is over the next game the opposite character will go first. The entire page will only reset if you refresh the page. If a draw happens no one will get the point and the game will refresh.
- Fork the repo from https://github.com/JWill06/tic-tac-toe
- Clone down the file into your local machine.
- Access that new directory.
- Type in "open index.html" in your terminal once inside the directory.
The total amount of time spent on this project was less than 7 hours.
- Jordan Williamson https://github.com/JWill06
- Write clear and dry functions.
- Event propogation/delegation.
- How to use one event for the entire box grid.
Wins
- Being able to use minimal lines of code in my JS file.
- Being able to properly target the entire grid instead of each individual box.
- Not getting stuck on a function for longer than 45 minutes.
Challenges
- Figuring out how to switch between characters. I did have to utilize some help from Phind but I was really close on my own.
- I had an issue with displaying the wins on both character sides, but then I realized I wasn't interpolating properly.