We all know that node. js is quite popular, out of the house, if you have not heard of node. JS, is basically out, the previous period of time to do a project, the use of real-time communication functions, when using node. js to do, I was fortunate to have studied some, other dare not say, the environment should be very skilled. First of all, I use the Windows environment, if you use a Mac or Linux, then you can bypass.
First, you can download a compatible version of your computer on the node. JS website: https://nodejs.org/download/, for example,
Here, I installed the Windows Installer.msi 64 bit, this time, point download. After the download, win7 words, click Install, always click Next, file installation address can be based on their preferences, C or D drive can be completed installation. Win8 words, run MSI file will be error, you can find the correct installation method on the Internet, you can download the source Code directly, after decompression can be used.
Second, the next step is to install, check the next node,npm command is OK, such as
In this way, after entering the command, you can see the version number, the description is OK, if "node is not internal or external command, is not a program to run", which indicates that there is no global variable, this time need to be configured in the system environment variable. Which, node I installed in D, node's address is D:\Program FILES\NODEJS\,NPM address is C:\USERS\ADMIN\APPDATA\ROAMING\NPM, the two address configuration to the environment variable path is OK.
Third, install Express, first in the command line Input command NPM install-g express-generator, install the Express command line tool, such as:
Install NPM Install-g Express again, and that's OK. The above installation is suitable for express4.0 more than the version, express4.0 the following direct installation
NPM Install-g Express is enough.
OK, the basic node environment configuration is OK, then you can fly freely in the world of node.
node. JS's Windows Environment Ultimate configuration