A 2-player Tic-Tac-Toe game built with React 18 via CDN. Runs as a single HTML file — no installs, no server, no backend needed.
| Layer | Technology |
|---|---|
| UI | React 18 (CDN) |
| JSX | Babel Standalone (in-browser) |
| Styling | Plain CSS |
| Backend | None |
- Download
tic-tac-toe.html - Double-click to open in any browser — game loads instantly
In VSCode: Install the Live Preview extension → right-click the file → Open with Live Preview
tic-tac-toe.html
├── CDN scripts (React 18 + Babel via unpkg)
├── <style> (all CSS)
└── <script> (JSX)
├── getResult() win/draw detection
├── <Square /> single cell
└── <App /> state, scores, handlers
- 2-player turns (X and O)
- Win detection — rows, columns, diagonals
- Draw detection
- Scoreboard with win/draw counts
- New Game and Clear Scores buttons
| Feature | Node.js | Spring Boot |
|---|---|---|
| Run this game | No | No |
| Persist scores | No (localStorage) | No |
| AI opponent | No | No |
| Online multiplayer | Yes | Yes |
- Any modern browser (Chrome, Firefox, Edge, Safari)
- Internet on first load (CDN scripts cache after that)