Cordova not recognized - node.js

I'm Running Windows 10 Node v5.8.0 and Cordova 6.0.0
I'm trying to install and use Cordova, The installation is successful but it gets installed to a file on my desktop the I ones installed a npm package (I long ago deleted that file - Node recreates it for me) instead of installing on the default location..
If I call Cordova from the local file where node has placed it, it will be recognized (but I can't create a new project next to it). and wherever I call Cordova outside of that location I'm getting this error message - 'cordova' is not recognized as an internal or external command,
operable program or batch file.
(This is the command I used for the installation - npm install -g cordova)

Related

React Native Expo error: "'node' is not recognized as an internal or external command, operable program or batch file" while setting up the project

While setting up the environment for an authentication app using React native and expo
These are the code I have ran:
expo init firebaseauth
npm install #react-navigation/native
expo install react-native-screens react-native-safe-area-context
npm install #react-navigation/native-stack
But while running expo install firebase in VS code terminal its is returning:
'node' is not recognized as an internal or external command,
operable program or batch file.
Action taken after that:
Installed the latest version of Node and NPM.
Set up the environment variable to C:\Program Files\nodejs
Restarted my system
Still its returning the same error in VS code terminal while running expo install firebase
'node' is not recognized as an internal or external command,
operable program or batch file.
After restarting the system, Node was recognized by my vs code terminal.
After that Yarn was throwing the same error.
I had to update Node, npm, yarn, and expo from Windows PowerShell as admin. Otherwise, none of it works if you don't update all of them from as admin.

NVM for windows error after installing nodejs

I'm completely new to nodejs and nvm , I installed nvm latest version and installed two nodejs versions.
C:\WINDOWS\system32>nvm list
10.10.0
08.12.0
I'm getting this error when I try to use nodejs
C:\WINDOWS\system32>nvm use 10.10.0
exit status 1: 'C:\Users\iClick' is not recognized as an internal or external command,
operable program or batch file.
Both nodejs folders are sitting inside nvm folder at
C:\Users\iClick Digital\AppData\Roaming\nvm
and these are system env var paths
NVM_Home C:\Users\iClick Digital\AppData\Roaming\nvm
NVM_SYMLINK C:\Programe Files/nodejs

'ng' is not recognized - Running an Angular app via electron

I know this question has been asked already, but the reply was not helpful to me.
I try to run an Angular app in electron by typing in Visual Studio code integrated terminal the following command:
npm start
The error I get is:
'ng' is not recognized as an internal or external command,
operable program or batch file.
The log file looks as following:
Now:
I have node installed:
Running command node -v gives me - v8.9.4
I have angular Cli inatalled.
Running the command npm list #angular/cli
gives me: `-- #angular/cli#6.0.3
I went to the folder of Environment Variable
The PATH variable looks as following:
C:\users\dim\AppData\Roaming\npm\node_modules\#angular\cli\bin;C:\Program Files (x86)\Microsoft VS Code\bin
What else can I do in order to solve the issue?
Your PATH variable should not contain C:\users\dim\AppData\Roaming\npm\node_modules\#angular\cli\bin but C:\users\dim\AppData\Roaming\npm.
Here are the .cmd files that are created when you install libraries globally :
npm i -g #angular/cli#latest

Cmmand issue - "ng" command not recognized as internal or external even when is in PATH Environment Variable [duplicate]

This question already has answers here:
ng is not recognized as an internal or external command
(51 answers)
Closed 3 years ago.
For some reason, yesterday, all my commands (ng, npm, node, etc.) were working fine, but at night I cleaned my PC from trash files and all that (my pc has Windows installed), and now it doesn't recognize the ng command, but all the others are OK.
I checked the Environment Variables and its path is there, I checked the path, and it's all right, I re-installed with:
npm install -g angular-cli**
However, nothing happened. I rebooted the computer and all that, but I just can't get ng working again.
I ran into this same snafu when I was trying to install Angular (v4.0) correctly. The way I corrected it, after I incorrectly executed npm install #angular/cli -- which generated a directory called node_modules.
To correctly install angular with npm, remove the directory node_modules, then simply start a new bash shell or simply open a new console or terminal tab, and execute sudo npm install -g #angular/cli. This may prompt you for your machine's password, so be prepared to enter it without being able to see it.
It seems like you were following the Angular weblog's instructions for installing Angular v4. You can do that instead instead just as easily; The key to installing Angular v4 correctly on my machine (besides updating my nodejs installation to the prerequisite latest version), was using sudo with the -g (aka. global) option.
At the end I made it work, I had to uninstall even all my NodeJs, de #angular/cli and the angular-cli, Rebooted my computer and then reinstalling NodeJs latest version and installed Angular with npm install -g #angular/cli#latest and removed from PATH and Environment Variables the old paths and got it running fine!
For me (In Windows) the problem was that the npm path was not saved in the path environment variable. If you browse to
C:\users\yourname\AppData\Roaming\npm
Inside this directory you can see ng (a javascript file) and ng.cmd (the windows command file that executes the javascript file). This path needs to be in your path variable to be able to call ng

What location does Node.js needs to be installed

I am trying to setup a project to work with Grunt. I need to install Node.js for that to run. I have downloaded and installed Node.js in c:\programfiles.
However when I try running npm install in my project c:\Grunt-proj , I get an error 'npm' is not recognized as an internal or external command.
Can someone help me with where to install Node.js? I am trying to follow this tutorial-
http://24ways.org/2013/grunt-is-not-weird-and-hard/
Many thanks,
The location is fine. I also have installed it in Program Files. But if you need to run the command npm from a command prompt then you need to add it to the path of the system. In my case I have C:\Program Files\nodejs

Resources