Vue builds a Vue project from scratch

The vue.js front-end framework builds a vue project from scratch. The process is as follows:

1. Install node.js

1. Enter the node.js official website to download the corresponding installation package: https://nodejs.org/en/ 

I downloaded the stable version here, and then downloaded and installed

 

  2. After the installation is complete, open the command line and enter node -v to determine whether the installation is successful

   3. When installing node, the npm package manager will be installed automatically. We output npm -v in the command to see if the installation is successful

 

 

4. Install Vue-cli scaffolding:

Two, npm package manager and vue-cli scaffolding to build
  1. Create a new folder to store the project files to be created, named here: vue-hhhls

 

2. Choose version 2.0 or 3.0 or custom, custom add the dependencies you want, I choose vue 2.0 here

 

3. Wait for the installation, the installation is successful as follows:

4.cd to the project folder and enter the command npm run serve to run the project

Let's copy the URL above and open the browser to visit it

 

5. When you see the following page, it is opened successfully, and the project is created successfully

 

 Finally, if you want to run and open the project yourself, you can configure the vue.config.js file yourself

 

 

 

Guess you like

Origin blog.csdn.net/H_hl2021/article/details/122084340