First, install node.js, you can install the latest version of the official website, because Vue-CLI requires Node.js version 8.9 or later (recommended 8.11.0+);
nodejs official website: https: //nodejs.org/en/
Second, verify node.js, npm installation is ok,
In cmd, enter commands and node -v -v NPM, the following results:
Third, the use npm tool download installation cnpm, because npm tool of foreign direct access Yes Yes server, so the domestic network is slow, it is recommended to take cnpm mirror download.
Installation image cnpm, enter in cmd: the install NPM = -g CNPM -registry https://registry.npm.taobao.org press Enter
Fourth, cnpm successful installation, use cnpm installation vue-cli3 scaffolding tools, refer to the official website: https: //cli.vuejs.org/zh/guide/installation.html
In cmd Input: cnpm install -g @ vue / cli carriage return, wait for the installation
If a Mac, enter sudo cnpm install -g @ vue in the terminal / cli
After a successful installation, you can enter the command:vue --version验证是否安装成功
V. After a successful installation, you can use the command: vue create vuedomo friends to create a project, which is to be created vuedemo project name
A step back is in accordance with the operation steps, such as query request next item, key switch down, the space choice, Enter.
Sixth, the project started in cmd, enter the command:
cd vuedemo
npm run serve
After running the command, the effect is as follows: