nodejs 笔记

1、nodejs —— 服务器

2、http —— 协议

3、

const http=require('http');
// 创建服务器(回调函数)
var server=http.createServer(function(req,res) {
    console.log('有人来了');
});

// 监听——等着
// 端口——数字
server.listen(8022);

request      请求 - 请求的信息

response   响应 - 输出的东西

后台

原文地址:https://www.cnblogs.com/sylys/p/12299696.html