Node.js的安装、调试

前言

Node.js 是一个基于 Chrome V8 引擎的运行在服务端的 JavaScript 运行环境。
Node.js 使用了一个事件驱动、非阻塞式 I/O 的模型,使其轻量又高效。

安装

安装node.js

从官网https://nodejs.org/en/下载最新的LTS版本

  • macox下用过brew安装
brew install homebrew/versions/node6-lts
echo 'export PATH="/usr/local/opt/node@6/bin:$PATH"' >> ~/.bash_profile

安装Nodeclipse CLI

$ npm install -g nodeclipse
$ npm install -g express@3.5.0
$ npm install -g express-generator
$ npm install -g coffee-script
$ npm install webpack -g
$ npm i -g yarn 

安装 Enide 2015 包含所有Nodeclipse插件

方式一:
Start Eclipse, then select Help > Install New Software…
Enter the update site URL into the Work with text box:
http://www.nodeclipse.org/updates/
安装后重启,通过Window -> Open Perspective -> Other … -> Node切换到node模式
- 方式二:
下载https://raw.github.com/Nodeclipse/eclipse-node-ide/master/ENodeIDE.p2f
打开eclipse–》File–》Import–》Install–》Install Software Items from file

Chrome安装插件JetBrains IDE Support

离线下载插件,拖拽该文件到chrome浏览器安装

调试

用inspect调试

Node.js自带debugger 调试器

用eclipse调试

在原有nodejs工程目录下执行

nodeclipse -p

其他类型工程或目录,执行

nodeclipse -g
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值