nodejs installation process in detail

What nodejs that?

Node.js is to establish a platform for running JavaScript in Chrome when, can easily build fast, scalable network applications. He said the popular point is the application programming platform, just out of the platform to write code browser.

  • It is a development platform
  • Not a framework
  • Nor is it a language

Why nodejs

  1. Nodejs is essential to learn the front, nodejs language based on Javascript, do not have to learn a single new strange language, thus reducing the threshold of learning, in order to unify the language around the table, you can achieve full stack development programmer, you can also unified public libraries, code standardization. This alone, nodejs has won the favor of the market.
  2. It is based on Google's V8 engine, V8 Javascript engine performs very fast, very good performance.

Nodejs installation environment

  • Download the official website address: http: //nodejs.cn/download/

    according to their own computers to choose to install, the installation operation is very simple
  • Detecting whether the installation was successful
    Here Insert Picture Description
    emergence as implied above represents a successful installation
  • Environment configuration (if configured installation packages and third-party global cache disk by default at c)
    The first step: create a new directory in the installation nodejs: "node_global" and "node_cache" two folders
    Here Insert Picture Description
    Step two: Enter cmd in the search in open command character enter the following command
    Node config prefix SET D: \ nodejs_web1804 \ node_global
    Node config the catch SET D: \ nodejs_web1804 \ node_cache
    then locate the user in the C disk .npmrc
    Here Insert Picture Description
    arrow points to two lines of code appears showing the configuration environment successfully
    step nodejs run js file code:
    maxTwo.js
    Here Insert Picture Description

Guess you like

Origin blog.csdn.net/wendy_QL/article/details/89185711