Build a Hybrid app – Build an Ionic development environment

In the ionic document, the installation environment is introduced:

Install ionic/Install Ionic

First you need to install Node.js. Second, install the latest version of cordova and ionic command-line tools. By referenceAndroid andiOS Official documents to install.

Tip: IOS needs to be installed on Mac Os X. Install and use under the Xcode environment (iOS development requires Mac OS X. iOS simulator through the Ionic CLI requires the ios-sim npm package, which can be installed with the command sudo npm -g install ios-sim.)< /span>

Give the link of node.js, you can download the installation package of node,

< span style="font-size: 12px;" > Then on the official website of node, you will see that there are installation packages for windows and mac systems, and only the source code under ubuntu system. Therefore, installing nodejs on ubuntu really took a lot of effort.

One. Install nodejs

There are many articles on the Internet about compiling and installing Node.js from source code, here I It is strongly recommended not to use this method. In most cases, package maintainers have a very clear understanding of the software structure, and developers do not need to compile the latest version of the source code from scratch.

The following method is applicable to the latest version of Ubuntu, Ubuntu 12.04 LTS, Ubuntu 12.10, Ubuntu 13.04 and other versions. It can help developers install Node.js on Ubuntu without compiling and installing from scratch. You can execute the following commands on the cloud host:

#apt-getupdate#apt-getinstall- y python-software-properties software-properties-common # add-apt-repository ppa:chris-lea/node.js #apt-get update # apt-get install nodejs

Once the command is executed, the latest The version of Node.js is installed, so there are no worries. Once the new version of Node.js is released, you can upgrade directly from the package manager without having to recompile and install from scratch.
Then, node is executed, execute the command:

$ node -vv0.10.25

< p>Second, install cordova and ionic cmd

sudo npm install-g cordova ionic pre> 

Execute after installation

cordova-v5.4.0
ionic-v1.7.10

So far, the installation is complete.

Leave a Comment

Your email address will not be published.