Spaces:
Sleeping
Sleeping
Initial Draft
Browse files
index.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
var express = require('express');
|
| 2 |
+
|
| 3 |
+
// Constants
|
| 4 |
+
var DEFAULT_PORT = 80;
|
| 5 |
+
var PORT = process.env.PORT || DEFAULT_PORT;
|
| 6 |
+
|
| 7 |
+
// App
|
| 8 |
+
var app = express();
|
| 9 |
+
app.get('/', function (req, res) {
|
| 10 |
+
res.send('Hello World\n');
|
| 11 |
+
});
|
| 12 |
+
|
| 13 |
+
app.listen(PORT)
|
| 14 |
+
console.log('Running on http://localhost:' + PORT);
|