/Tic-Tac-Toe

Browser-based tic-tac-toe game.

Primary LanguageJavaScript

Tic-Tac-Toe

Completed through The Odin Project

cedrus32.github.io/tic-tac-toe/

This project is my first attempt at using IIFEs and factory functions to structure an application. It was a challenge to visualize how the functions worked together, where to place variables/helper functions, and how to share these objects across manager functions. While the code works, areas of future improvement include spending more time in the planning stage laying out how different functionalities communicate with each other, and cleaning up the code's organization to reduce the amount of 'getXVariable()' helpers to pass information between managers.

This is also the first project where I attempted to split JS code into separate files. I separated gameplay, player selection, and theme selection functionalities into separate JS files. An area of improvement with this approach is sharing variables across JS files, rather than repeating declaration in each.

Thanks to Stephen Ostermiller's post on tic-tac-toe strategy, Material Design Icons for theme and player icons, Jongcreative for vector design and inspiration, and SVGator and Vectornator for their svg creator tools.