MultiplayerMinesweeper/scripts/server/server.mjs

11 lines
303 B
JavaScript

import path from 'path';
import express from "express"
import { port } from "../env.mjs"
var app = express()
const __dirname = path.resolve(path.dirname(''));
app.use(express.static(__dirname + '/www/'));
export var webServer = app.listen(port, function () {
var port = webServer.address().port;
});