I tried to install twitter bower on my Mac, and I used
npm install bower -g
Then I tried bower --help, and the output was bower command not found. Why is that?
bower --help
bower command not found
Just like in this question (npm global path prefix) all you need is to set proper npm prefix.
npm prefix
UNIX:
$ npm config set prefix /usr/local $ npm install -g bower $ which bower >> /usr/local/bin/bower
Windows ans NVM:
$ npm config set prefix /c/Users/xxxxxxx/AppData/Roaming/nvm/v8.9.2 $ npm install -g bower
Then bower should be located just in your $PATH.
bower
$PATH
2.1m questions
2.1m answers
60 comments
57.0k users