1

I know the question has been asked many times but really none of them helped me. I'm on windows 10 and have successfully installed bower via npm using the following code

npm install -g bower

I've added the path to system environment variable but still getting the same error bower is not recognized as internal or external command.

I've added the following path into my system environment variable

C:\Users\habib\AppData\Romaing\npm

While when I try

  npm config get prefix
 C:\Users\habib\AppData\Romaing\npm

When I try

npm bower -v

I get the bower version

Tried this as well This

Neither of them worked for me.

Why is that so?

Community
  • 1
  • 1
Basheer Kharoti
  • 4,202
  • 5
  • 24
  • 50

4 Answers4

5

I've tried set the Path variable value in Users Environment variable to the same as for System Environment variable and it worked...

C:\Users\<username>\AppData\Roaming\npm
m.rufca
  • 2,558
  • 2
  • 19
  • 26
Basheer Kharoti
  • 4,202
  • 5
  • 24
  • 50
5

I've edited the path variable in the environment variables and set it up to the following path and it has worked for me.

C:\Users\<username>\AppData\Roaming\npm\node_modules\bower
Muhammad Hamza
  • 231
  • 3
  • 7
0

For windows users -> If even after adding the path to the environment variables , it doesnt work , try using bower through a git bash shell instead of the windows command prompt. . Mine worked that way.

Ozesh
  • 6,536
  • 1
  • 25
  • 23
-2

Set user variable path - C:\Program Files\Nodejs and set system variable path - C:\Users\pk-03\AppData\Roaming\npm