Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted over 1 year ago

Tic tac toe game using Vanilla JavaScript, HTML, and CSS

Isabella Lizarde•90
@isabella-lizarde
A solution to the Tic Tac Toe game challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


I decided to build this project using Vanilla JavaScript, HTML, and CSS to practice the basics and deepen my understanding of the core foundations.

The difficulties I encountered was creating the logic for the winning combinations and next round functions. I also had issues with the hover effects for the game board cells. Depending on what mark the user chooses to play as it should correctly hover either X or O, but when the game is played on a mobile screen the hover effect is removed. I'm planning on implementing the Minimax algorithm but for now the computers moves are random.

After testing my project I believe it should be working fine, but if anyone encounters any errors on their end I would appreciate the feedback. Thanks!

Code
Loading...

Please log in to post a comment

Log in with GitHub

Community feedback

No feedback yet. Be the first to give feedback on Isabella Lizarde's solution.

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License