Uncaught ReferenceError: angular is not defined - Mean.IO

I had the same problem and I solved in this way:

You need to install or reinstall "bower"

Check your bower.json file, it should look something like this:

{
"name": "mean",
"version": "0.3.0",
"dependencies": {
    "angular": "latest",
    "angular-resource": "latest",
    "angular-cookies": "latest",
    "angular-mocks": "latest",
    "angular-route": "latest",
    "bootstrap": "latest",
    "angular-bootstrap": "0.10.0",
    "angular-ui-router": "#master"
  }
}

and then run the following command:

  sudo bower install --allow-root

This will install to "Angular" in the project


I had the same problem but for some reason the top answer here (reinstalling bower and running sudo bower install --allow-root) didn't work for me.

However the answer form this stackoverflow thread worked -> bower command not found Basically the author there said I wasn't setting npm prefix properly and to fix that the following was required:

$ npm config set prefix /usr/local
$ npm install -g bower