Weex front-end framework to build nodejs in small projects.

Recently want to learn nodejs, the front end of the frame you want to use and then weex want to install a weex framework.

First we have to install their own nodejs,

Nodejs own judgment whether the installation is successful, they can open their own dos window, and then validate their own input node -v view their version number in the window. Figure:

Then it can be installed directly weex this framework, but that she tried several times without success to install, and then had to change their own method of installation. Successful one is to install their own success through Taobao mirrored cnpm.

When we installed the nodejs, by configuring their own environment variables, you can configure their own environment variables.

Then we can as shown above in FIG. In a statement entered in dos

cnpm install -g weex-toolkit

Weex to install their own framework.

Then we can be their first app set up.

Terminal in our webstorm in our input

weex create awesome-app

To create an empty template of our project: as shown:

Then let us keep pressing Enter, know this thing is over.

Development began

The next step is to enter the amount of the folder you just created, and install dependencies,

Then execute npm start

cd swesome-app

npm install 

Elevation start

Then the tool will start a local web server or through the 8081 port. You can open a terminal in their webstorm provided you can enter into the url

A page template

as the picture shows:

Some might be:

http: // localhost: 8081 but, as my chart is shown in this Web site. The terminal webstorm map with the truth.

 

Guess you like

Origin www.cnblogs.com/littleswan/p/11288328.html