First step: Download the installation file
Download Nodejs, official website: http://nodejs.org/download/, I download here is Node-v0.10.28-x86.msi, such as:
Step Two: Install Nodejs
After the download is complete, double-click "Node-v0.10.28-x86.msi" to start installing Nodejs and customize the installation under D:\dev\nodejs.
In the cmd console input: node-v, the console will print out: v0.10.28, the version prompt indicates that the installation was successful .
This boot step installs the Node.exe file into the D:\dev\nodejs\ directory and adds the directory to the PATH environment variable.
Step Three: NPM installation
Since NPM has been integrated with the new version of Nodejs, NPM has been installed as well. You can also use the cmd command line to enter "Npm-v" to test for successful installation. For example, a version prompt indicates that the installation was successful.
Fourth step: Install the relevant environment
NPM Install Express--G
By default, the above components are installed under the D:\dev\nodejs\node_modules folder, which is also the auto-find path for NODEJS related components.
Fifth Step: Install Coffeescript
NPM Install Coffee-script-g
Confirm the installation of the command: COFFEE-V, the version number that appears indicates a successful installation.
Sixth step: Coffeescript Test Example
To create a new Cs.js file, enter:
for inch [0...5"Hello #{i}"
Run the "coffee cs.js" output in this directory:
D:\>01234
The above environment is basically configured to complete.
Additional notes:
All commands are globally installed by-G, so that the installation packages are installed under the current user and can be accessed in all other areas of the disk, in comparison. Otherwise, it is installed in the current directory and can only be used in the current directory.