Error installing ionic on Mac OS - ionic-framework

I'm trying to install the ionic on but it has error.
I've checked other articles here, but their solution does not help.
I am using the command:
sudo npm install -g ionic cordova
I am with:
$ npm --version
3.10.9
$ node --version
v6.9.2
And the error:
UPDATE:

There are mentions of this on the ionic forums if you do a search there
What I would so is completely remove ionic and Cordova by running
npm uninstall -g cordova
And
npm uninstall -g ionic
Then I would start the process again with
npm install -g cordova ionic
Just note that this docs say to install Cordova and then Ionic whereas it looks like you did it the other way around which could have caused some issues.

Related

How this error occure in ionic installation?

I can't install ionic in windows 10 please help me to install and configure the ionic s/w
I already changed my node version and node-gyp command. but nothing changed
An error occurred while running node install (exit code 1)
Run this
first uninstall ionic completly
npm uninstall -g cordova
npm uninstall -g ionic
install again
npm install -g ionic

Ionic installation on macOs

I am trying to install ionic and every time I try to install it says:
npm WARN deprecated node-uuid#1.4.8: Use uuid module instead
and I can't even check ionic -v to check version as it is not installed.
I can check npm version as it is installed correctly.
➜ ~ node -v
v8.7.0
➜ ~ npm -v
5.4.2
➜ ~ npm install -g cordova ionic
npm WARN deprecated node-uuid#1.4.8: Use uuid module instead
/Users/bilaltariq/.npm-packages/bin/cordova -> /Users/bilaltariq/.npm-packages/lib/node_modules/cordova/bin/cordova
/Users/bilaltariq/.npm-packages/bin/ionic -> /Users/bilaltariq/.npm-packages/lib/node_modules/ionic/bin/ionic
+ cordova#7.1.0
+ ionic#3.13.2
updated 2 packages in 27.258s
Had the same problem. The fix is to install ionic CLI globally:
As the developer user execute the following from your ionic project root directory:
npm uninstall ionic
then as user "root" execute the following:
npm i -g ionic#latest
after that, you should be able to use the new ionic CLI version 4.12.0

ionic1 error: TypeError: Cannot read property 'emit' of undefined

i am making a application using ionic1 and angularjs1.
Today, when i execute ionic serve command in terminal. then i got following error.
js#js:peoject$ ionic serve
[INFO] Starting server: --port=8100 --p=8100 --livereload-port=35729 --r=35729 --address=0.0.0.0 - Ctrl+C to cancel
TypeError: Cannot read property 'emit' of undefined
from last 2-3 months there was no any issue but today suddenly i faced with this issue.
My ionic version is 3.3.0
Is there anything update on ionic or what else? i dont understand.
I tried a lot and the solutions is very simple.
My previous version of ionic was 2.2.0
So, i downgrade the ionic version.
First, remove the ionic, then reinstall with your old version.
harish#harish: sudo npm uninstall -g ionic
harish#harish: sudo npm install -g ionic#2.2.0
or
harish#harish: sudo npm uninstall -g ionic
harish#harish: sudo npm install -g ionic#2.2.3
or
harish#harish: sudo npm uninstall -g ionic
harish#harish: sudo npm install -g ionic#2.3.0
Whatever the version is, just uninstall your latest ionic and install your old version.
Then the issue is solved.
I had the same error downgrade your ionic version.
sudo npm install -g ionic#2.2.3
This worked for me.
reinstall the ionic
npm uninstall -g cordova ionic
npm install -g cordova ionic
this solved my same problem

Ionic Framework : How to Upgrade to Ionic 2

I use ionic stable version to build Hybrid Mobile Application and things going fine.
Now, I would like to use Ionic 2 for its components features. Hence, I have installed ionic on ubuntu as
$ npm install -g ionic#beta
And then start using ionic started template as
$ ionic start IonicMyV2 --v2
However, the above command always brings the stable version ionic template.
What I am doing wrong? What procedure do I have to follow to use Ionic 2?
My problem has been resolved by command
sudo npm install -g ionic#beta cordova
You can remove the need for sudo with npm by installing NodeJS via brew:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install node
node -v
npm -v
npm install -g ionic#beta
You should run below command for upgrade to ionic 2.
npm install -g cordova ionic

Error while installing the ionic framework

I want to install the ionic framework on my windows 8 laptop but it is showing the following warning when i am trying to use the command
npm install -g cordova
I am already installed
1.Nodejs
2.Git-scm
Please Help me to install the ionic framework
Install all necessary dependencies. http://ionicframework.com/docs/guide/installation.html
Download and Install node.js
Install Cordova using the command: npm install -g cordova
Finally install Ionic Framework using the command: npm install -g ionic