Skip to content

Commit 2a7390c

Browse files
committed
add api project
1 parent c8ac7ff commit 2a7390c

14 files changed

Lines changed: 14538 additions & 0 deletions

File tree

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,4 @@ A few projects that show case a few Javascript framework/libaries.
1616
- [Exploit](https://github.com/aakhtar3/javascript-projects/tree/master/node/exploit) 2019
1717
- [Quiz API](https://github.com/aakhtar3/javascript-projects/tree/master/node/quiz-api) 2020
1818
- [Vesting CLI](https://github.com/aakhtar3/javascript-projects/tree/master/node/vesting) 2020
19+
- [API](https://github.com/aakhtar3/javascript-projects/tree/master/node/api) 2022

node/api1/README.md

Whitespace-only changes.

node/api1/app.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/* Application Server with Port Listener */
2+
const server = require('./src/server');
3+
const port = (process.env.PORT || 3000);
4+
const handler = (port) => console.log(`App listening at http://localhost:${ port }`);
5+
6+
server.listen(port, handler(port));

0 commit comments

Comments
 (0)