Refactor 4 with bugfixes
This commit is contained in:
14
server/src/app.ts
Normal file
14
server/src/app.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import express from 'express';
|
||||
import cors from 'cors';
|
||||
import { registerRoutes } from './routes';
|
||||
|
||||
export function createApp(): express.Express {
|
||||
const app = express();
|
||||
|
||||
app.use(cors());
|
||||
app.use(express.json());
|
||||
|
||||
registerRoutes(app);
|
||||
|
||||
return app;
|
||||
}
|
||||
Reference in New Issue
Block a user