Linux下安装node.js
yum install -y nodejs
node -v
v6.11.3
npm -v
3.10.10
hellowolrd
vim helloworld.js
node helloworld.js
hello, world
var http = require('http')
http.createServer(function (request, response) {
console.log('访问');
response.write('hello, world');
response.end();
}).listen(8000);
console.log('Server running at http://127.0.0.1:8000/');
参考文档
Vim配置Node.js开发工具
http://www.cnblogs.com/zhanghaiyublog/p/3649959.html
node.js教程1_安装和hello
http://edu.51cto.com//center/course/lesson/index?id=124524
网友评论