fix: correction d'erreurs de copie

This commit is contained in:
2026-08-02 23:27:55 +02:00
parent 45ad31d0ae
commit 4d57dfa233
5 changed files with 18 additions and 24 deletions

View File

@@ -9,4 +9,17 @@ const path = require("path");
const http = require("http");
const { Server } = require("socket.io");
const { PORT } = require("./config.js");
const { PORT } = require("./config");
const { registerSocketHandlers } = require("./socketHandler");
const app = express();
const server = http.createServer(app);
const io = new Server(server);
app.use(express.static(path.join(__dirname, "..", "client")));
io.on("connection", (socket) => registerSocketHandlers(io, socket));
server.listen(PORT, () => {
console.log(`Serveur démarré sur http://localhost:${PORT}`);
});