add server (Express app)

This commit is contained in:
João Geonizeli
2022-07-08 16:20:42 -03:00
parent 1cfa4ce55e
commit df113c34ee
6 changed files with 1018 additions and 0 deletions

15
server/src/index.ts Normal file
View File

@@ -0,0 +1,15 @@
import dotenv from 'dotenv';
import express, { Express } from 'express';
dotenv.config();
const app: Express = express();
const port = process.env.PORT;
app.get('/', (req, res) => {
res.send('Hello World!');
});
app.listen(port, () => {
console.log(`Server is running at ${port}`);
});