简体   繁体   中英

How to check that Node JS is installed correctly?

I'm completely new to OSX. I've tried to install Node JS using Terminal following step-by-step tutorial. How do I check that Node JS is installed successfully? Are there any commands or GUI interface equivalent to "Programs and Features" in Windows?

Thanks, DV

在终端中输入node -v ,如果节点安装正确,您应该会看到显示的节点版本。

The node.js executable (binary) should be node, not nodejs. However, there was a naming conflict on some Linux distros (eg, Ubuntu), resulting in the executable getting installed as nodejs. As of Ubuntu 14.04, for instance, apt-get install nodejs will also install executable node (implemented as a symlink to nodejs). In other words: For consistency, try node -v first.

$ node -v

if symlink was used

$ nodejs -v

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM