I've been trying to install phonegap with no luck.
I've already installed nodejs using:
sudo apt-get install node
But when I tried to run the following, nothing was outputted to the terminal. See attached image.
sudo npm install -g phonegap
Package name should be "nodejs" not "node".
Also make sure npm is installed by typing :
npm -v
in terminal.
Please read Installing Node.js via package manager for Node.js & NPM installation.
Related
I'm trying to update my Ionic Cli from 6.12.2 to the latest version (6.19.0). I'm using Ubuntu. I was able to update node.js to the latest version, but when I run the commands:
npm uninstall -g ionic
npm uninstall -g #ionic/cli
with or without sudo command, when I run ionic -v again, it still say that I have the version 6.12.2 of ionic. and when I run npm install -g #ionic/cli and then run ionic -v it still say the same. Those commands are not being able to remove ionic from my Ubuntu.
That is something like a cache folder on ubunt that I should delete from system, related with the ionic cli, or something like that? Because I was not able to do this following the documentation on website.
To work around the problem, you can install the latest version from tarball:
cd /tmp
wget https://registry.npmjs.org/#ionic/cli/-/cli-6.19.0.tgz
sudo npm -g install cli-6.19.0.tgz
I'm trying to install Angular on macOS. I have npm 5.6.0 and node 8.11.1 installed. I tried sudo npm install -g #angular/cli, which seems to install it. However, when I type ng --version, I get:
Unknown error: ReferenceError: Invalid left-hand side in assignment
Edit: I also tried this, to no effect:
npm uninstall -g angular-cli
npm cache clean or npm cache verify (if npm > 5)
npm install -g #angular/cli#latest
You can use the macOS package manager. In your terminal type:
brew install angular-cli
To confirm your version:
ng --version
I think the best way to install angular on mac is using brew.
1.) Install brew, by typing the following command on your terminal :-
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
2.) After Installing brew, then run following command :-
brew install angular-cli
After Installation, you'll see angular is successfully installed.
To check, Type Command :-
ng version
Delete npm and node, then install them via brew (works perfect on mac os).
See https://brew.sh/
npm install -g #angular/cli
I am trying to install angular cli on Windows 10, I have already installed npm and node, and have verified their version, they are above then what is required for angular cli to install but when I run install command on the prompt it show error.
i have uninstalled npm and node, then reinstalled them, and tried again to install and it worked :) thanks
first try to see node and npm is installed successfully using following commands on cmd
node -v
for node and it will return the version of node,then
npm -v
then it will return the version of npm after that in windows go to environment variables and see node environmental varible is there. after that
npm cache clean --force
use to clean the cache and go to users/Appdata/roaming and delete all the node modules in npm cache folder and restart your computer and give the following command.
npm install -g #angular/cli
I'm trying to install ionic in my ubuntu laptop.
I have successfully installed Node.js and Cordova. They are working properly.
But when I try to install Ionic from sudo npm install -g ionic it doesn't give any output.
Then I wrote ionic in cmd, it says No command 'ionic' found,
Any idea about this is really appreciated.
cmd outputs
Your npm is not correctly installed. Try to uninstall it and install again.
I installed npm and node via command
brew install node successfully. And the terminal showed the version of npm and node when I typed in node -v and npm -v.
However, when I tried to install Karma via sudo npm install -g karma, the terminal showed npm:command not found. And I turned to /usr/bin, there was no npm there.
What's wrong with my installation? Thanks!