Skip to content

Instantly share code, notes, and snippets.

@pramodmg
Created August 1, 2021 19:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pramodmg/896371ee17fb6221c53ec5c9d93d8028 to your computer and use it in GitHub Desktop.
Save pramodmg/896371ee17fb6221c53ec5c9d93d8028 to your computer and use it in GitHub Desktop.
Setting up the express web server - simplest way
{
"name": "express-web-server",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"start": "node simpleRoute.js"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"express": "^4.17.1"
}
}
const express = require('express');
let app = express();
const port = 3009;
app.listen(port, () => console.log(`listening on ${port}`));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment