Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

express start template

const express = require('express');
const app = express();
const cors = require('cors');
const port = 4000;
app.use(cors());
app.use(express.json());

app.get("/", (req, res) => {
  res.send("Hello");
});

app.listen(port, () => {
  console.log(`Server running on http://localhost:${port}`);
});
 
PREVIOUS NEXT
Tagged: #express #start #template
ADD COMMENT
Topic
Name
6+1 =