A responsive Tic Tac Toe Game Using React
This is the code for a basic Tic Tac Toe game made with React. It originated from an assignment in Week #16 of MIT's MERN Coding Bootcamp. The challenge was to demonstrate the ability to communicate between parent and child components and add features.
- React state and callbacks are used to communicate between parent and child components of the game.
- React is used to maintain current player and an array of game state properties.
- Styling is spearated from the code with a cascading style sheet.
- Grid layout is used for the layout of the game board.
- Fork this repository
- Clone copy to your desktop
- Open a command line on your computer and run the command cd path/to/project/root. (path/to/project/root should be replaced with the actual path to the project folder)
- Within the same command-line window, run 'npm install' to install all dependencies.
- Within the same command-line window, run 'npm start' to start the application in your browser.
- Disable square after a player has clicked it
- Create a Clear button to start a new game
- Set next player message to game over after winner declared or board full
- Add text for when the game is a draw/tied
- Bill Conley
- Dr. John Williams
Copyright (c) 2021 Bill Conley
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.