Quick understanding of Node. js environment configuration in the Window of node. js, Node. jsnodejs

Source: Internet
Author: User
Tags install node

Quick understanding of Node. js environment configuration in the Window of node. js, Node. jsnodejs

In the window, I also tried it. The installation was complete and the test passed!

1. Download node

Download node at https://nodejs.org/en/and select the stable version on the left.

2. Install node

Install the downloaded node step by step.

3. Check whether node is successfully installed after installation.

After installation, a command window is displayed at the start of window.

Check the node version after enabling

4. Install Global Express

5. Check whether Express is successfully installed.

6. demo Test

1) Create helloWorld. js

var http = require("http"); http.createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.write("Hello World"); response.end(); }).listen(8899); console.log("nodejs start listen 8899 port!");

2) Place helloWorld. js in the F: \ nodejs \ node_modules \ npm \ test directory.

3). Start the output

Use the command line to point to the upper-level directory of helloWorld. js and start express

7.

Running result

Enter http: // 127.0.0.1: 8899 in the browser. The output result is as follows:

By l'oreal Paris

The above is all the content of this article, hoping to help you learn.

Articles you may be interested in:
  • Simple nodejs installation and environment configuration in windows
  • Use Shell scripts to quickly build the Nodejs development environment in Ubuntu
  • Node. js (1) --- Introduction to Node. js and installation and development environment
  • Build Nodejs development environment in Ubuntu
  • Configure and use the node. js Development Environment
  • Nodejs tutorial environment installation and running
  • Use Sublime in Windows to build the nodejs Environment

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.