Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

what is node

npm install http then write a webserver...
const http = require('http');
const PORT = 3000;

const server = http.createServer((req, res) => {
  res.statusCode = 200;
  res.setHeader('Content-Type', 'text/plain');
  res.end('Hello World');
});

server.listen(port, () => {
  console.log(`Server running at PORT:${port}/`);
});
Source by www.tutorialspoint.com #
 
PREVIOUS NEXT
Tagged: #node
ADD COMMENT
Topic
Name
7+9 =