File size: 355 Bytes
2e22a88
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import * as express from "express";

const expressApp = express();

expressApp.get("/", (req, res) => {
	res.json({ hello: "world" });
});

expressApp.post("/", (req, res) => {
	console.log(req.body);

	res.json({ success: true });
});


const PORT = 7860;
expressApp.listen(PORT, () => {
	console.debug(`server started at http://localhost:${PORT}`);
});