I have my fully working app here that I’m trying to host on a localhost server using Express.js
https://jsfiddle.net/mostafa91/6axesy2t/2/
Here is my server.js that I run with “node server.js”:
const express = require('express');
const app = express();
const port = 2525;
app.get('/', (req, res) => {
res.sendFile(__dirname + '/public/Gameboard.html');
});
app.listen(port, () => {
console.log(`Tic-Tac-Toe listening at http://localhost:${port}`);
});
app.use(express.static('public'));
I keep getting errors when I try to play the game (vs. Players option):
Uncaught TypeError: Cannot read properties of null (reading 'classList')
at setBoardHoverClass (Gameboard.js:74)
at startGame (Gameboard.js:32)
at Gameboard.js:20