Add express backend server

This commit is contained in:
2022-05-01 16:49:45 +02:00
parent 495771b0e8
commit 8da44976e1
4 changed files with 1050 additions and 0 deletions

6
server/.eslintrc Normal file
View File

@ -0,0 +1,6 @@
{
"env": {
"node": true,
"commonjs": true
}
}

11
server/index.js Normal file
View File

@ -0,0 +1,11 @@
import express from "express";
const app = express();
const port = process.send.PORT || 3000;
app.get("/", (req, res) => {
res.send("Hello World!");
});
app.listen(port, () => {
console.log(`Server listening on http://localhost:${port}`);
});

1018
server/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

15
server/package.json Normal file
View File

@ -0,0 +1,15 @@
{
"name": "timetable-server",
"version": "1.0.0",
"description": "",
"main": "index.js",
"type": "module",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "minie4",
"license": "ISC",
"dependencies": {
"express": "^4.18.1"
}
}