Tic Tac Toe


2 player game x and o


March 2016

tools used

HTML, SCSS & jQuery


Create a grid of 3 * 3 in html and add class names to each square. Use a count to keep track of clicks and add either an x or o to the grid on click of a square. Run checks that cover a win or draw scenario based on the text content within the grid. Display the result and add an option to restart the game.


Testing html content from users clicks. Keeping track of turns. Updating the dom. Refreshing the page on click. Basic game logic.

See the Pen Tic Tac Toe by Harry Beckwith (@fun) on CodePen.

← Back to all projects