Initial commit
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"name": "@nirvana/api",
|
||||
"version": "1.0.0",
|
||||
"main": "index.js",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"express": "^4.17.3"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
const express = require('express');
|
||||
|
||||
const app = express();
|
||||
|
||||
app.use((req, res, next) => {
|
||||
console.log('Time: ', Date.now());
|
||||
next();
|
||||
});
|
||||
|
||||
|
||||
app.get('/', (req, res) => {
|
||||
res.send('Successful response.');
|
||||
});
|
||||
|
||||
app.listen(5000, () => console.log('Example app is listening on port 5000.'));
|
||||
Reference in New Issue
Block a user