feat(logging): add logger
This commit is contained in:
parent
7c84025f3c
commit
aae85cd767
15 changed files with 240 additions and 17 deletions
|
@ -4,6 +4,7 @@ import cors from 'cors';
|
|||
import http from 'http';
|
||||
import routes from './routes';
|
||||
import { getPort } from './config';
|
||||
import logger from './utils/logger';
|
||||
|
||||
const port = getPort();
|
||||
|
||||
|
@ -23,7 +24,7 @@ app.get('/api', (_, res) => {
|
|||
});
|
||||
|
||||
server.listen(port, () => {
|
||||
console.log(`API server started on port ${port}`);
|
||||
logger.info(`Server is running on port ${port}`);
|
||||
});
|
||||
|
||||
startWebSocketServer(server);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue