How to install ionic in ubuntu Desktop 16.04.LTS

Hi,

Is there an installer package how to use Syncfusion Ionic on ubuntu is there an npm or other install packages.
Thanks for the support.

Regards,
James redbox tv

Hello, the only way to install ionic is via npm. For that you need to install nodejs first and then install ionic with:

sudo npm i -g ionic cordova

To install nodejs and npm:

sudo apt install nodejs && sudo apt install npm
1 Like

Please ignore the previous post, never use sudo unnecessarily, and instead install nvm.

1 Like

You can also install nodejs and npm via nvm, like @rapropos says with this commands:

curl -o- https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash

source ~/.bashrc #reload your bash file

nvm install --lts #--lts option is for the long supported version

And then you will have nodejs and npm installed on your machine. Now you only need to install ionic with npm.

Thanks for sharing.

That’ what i was thinking. There is no need to use sudo for that.

The docs say to use it tho https://ionicframework.com/docs/v1/guide/installation.html

Node and npm are a very complex package management ecosystem. In a manner of speaking, it is almost as if you are installing something as comprehensive as a separate OS. When you run npm with elevated privileges, you are effectively entangling the npm OS with your underlying OS, because npm is going to write a bunch of files in places that are hard to even track, let alone corral. Once you run npm under sudo even once, then you have committed yourself to doing it every time.

The primary reason I am so emphatic about using nvm instead of sudo is this: now and again, something goes sideways. It happens to all of us. If you regularly read support forums like this, you will see countless examples.

You can fastidiously use strace to try to find all of the tens of thousands of files that npm is looking for when you run a problematic command. You can hunt them all down, theorize about conflicts, scour the internet in the hope that somebody else out there happened to have just exactly the same problem you do. If that all turns out to be fruitless, your only real recourse is to completely vaporize your OS and install from scratch. Maybe next time you’ll do your node work inside a VM, so that OS is walled off from your host OS containing all your personal stuff that is such a pain to keep restoring from backups.

Or, you could just avoid doing any of that and type:

$ nvm uninstall <version>
$ nvm install <version>

The choice seems crystal clear to me.

1 Like

thanks RCODeGO for your answer…! it really helped me a lot.

Hello,
Ionic provides and command line utility for creating packages, build and start applications. Use npm command to install Ionic framework on your system.
Thanks for you

awesome answer, thanks for sharing