Error:'bower' is not recognized as an internal or external command, operable program or batch file

0 votes

 I have re-installed the Node JS, NPM and the problem started. After I install a module like example npm install -g bower, the module gets installed successfully but bower -v gives

'bower' is not recognized as an internal or external command, operable program or batch file.

I have checked the installation path C:\Users\XXXXX\AppData\Roaming\npm\node_modules which has all the old installed modules. I have tried to uninstall them and reinstall the modules, but still I am getting the same error.

Even I have deleted the entire folder and installed all the modules again but the result is same.

I don't know why I am getting this error after reinstalling NodeJS NPM.

Oct 14 in Node-js by kartik
• 35,720 points
125 views

1 answer to this question.

0 votes

Hello @kartik,

Fixed it by adding the 'npm' directory to my PATH:

Right click 'My Computer' and go to 'Properties > Advanced System Settings > Environment Variables'.

Double click on PATH under the 'User variables for Username' section, and add 'C:\Users\niroj/AppData\Roaming\npm' obviously replacing 'username' with yours.

Restart your console window or IDE and you should get a response from the bower command.

Hope it helps!!

Thank You!!

answered Oct 14 by Niroj
• 77,920 points

Related Questions In Node-js

0 votes
1 answer

Error:nvm is not compatible with the npm config "prefix" option:

Hello @kartik, After installing nvm using brew, create ~/.nvm directory: $ ...READ MORE

answered Jul 15 in Node-js by Niroj
• 77,920 points
534 views
0 votes
1 answer

Error:sudo: npm: command not found

Hello @kartik, I had the same problem; here ...READ MORE

answered Jul 15 in Node-js by Niroj
• 77,920 points
3,612 views
0 votes
1 answer

How to execute an external program from within Node.js?

Hello @kartik, Exec has memory limitation of buffer ...READ MORE

answered Jul 17 in Node-js by Niroj
• 77,920 points
397 views
0 votes
1 answer

Error:/usr/bin/env: node: No such file or directory

Hello @kartik, You have to manually link to ...READ MORE

answered Oct 11 in Node-js by Niroj
• 77,920 points
222 views
0 votes
1 answer

jQuery AJAX fires error callback on window unload - how do I filter out unload and only catch real errors?

Hello, In the error callback or $.ajax you have three ...READ MORE

answered Apr 27 in Java-Script by Niroj
• 77,920 points
447 views
0 votes
1 answer

How do I pass command line arguments to a Node.js program?

Hello @kartik, If your script is called myScript.js ...READ MORE

answered May 5 in Java-Script by Niroj
• 77,920 points
695 views
0 votes
1 answer

Error:Issue when trying to use IN() in wordpress database

Hello @kartik, Try this code : // Create an ...READ MORE

answered May 8 in PHP by Niroj
• 77,920 points
91 views
+2 votes
1 answer

How do I debug Node.js applications?

Hello @kartik, Use node-inspector  from any browser supporting WebSocket. Breakpoints, ...READ MORE

answered Jul 8 in Node-js by Niroj
• 77,920 points
87 views
0 votes
1 answer
0 votes
1 answer

Error:node' is not recognized as an internal or external command

Hello @kartik, Node is missing from the SYSTEM ...READ MORE

answered Oct 15 in Node-js by Niroj
• 77,920 points
186 views