Recently wanted to develop projects with bootstrap in order to use their rich resources;
Adjusting supervised the installation and configuration of Nodejs, Windows to get up or compare the dog excrement, two or three days off work time to fix;
http://xiaoyaojones.blog.163.com/blog/static/28370125201351501113581/
This link describes the relatively clear, especially for the Nodepath configuration introduced relatively thin;
In fact, the installation is very simple, mainly installed after the package is more trouble;
Here is the command to record the installation:
NPM config set prefix "C:\Program files\nodejs\node_global"
NPM config set cache "C:\Program files\nodejs\node_cache"
The directory drive does not matter, here is set two global variables corresponding to the location, convenient for subsequent installation of the required package;
NPM Install-g Express is installed in the Node_global under the package, after the execution to Node_global\node_modules can see the installed Express package;
Another: Will encounter the download is very slow situation, that is, the implementation of NPM install does not respond; Online search netizens generally said CNPM more reliable, faster;
Reference the following here the Watercress article;
http://www.douban.com/note/341028091/
But still want to endure first put CNPM install, can use CNPM;
I installed the method: NPM install-g cnpm--registry=http://r.cnpmjs.org
Installation completed;
Use set Prefix/set cache to set the directory as usual;
This installs the content with the original NPM installs the same place;
CNPM Install-g Express--registry=http://r.cnpmjs.org
Or you can install the package you want to use directly cnpm installed Express;
As for the Nodepath is mainly to be installed in the content of the upper directory, namely: their own configuration of the Node_global\node_modules directory can be;
Mine is: E:\Program files\nodejs\node_global\node_modules such;
A few more words: the installation of such actions, and the previous Haskell package installation is very similar, but also to download the necessary things, the pattern is very similar, just contact, and then continue to learn ...
node. JS Bootstrap Installation