angularjsbower-install

Unable to find a suitable version for angular while running bower install command


I am getting the following message while running bower install command.

enter image description here

enter image description here

bower.json:

{
  "name": "test-app",
  "version": "1.1.6",
  "dependencies": {
               "jquery": "2.1.0",
               "jquery-bridget": "*",
    "angular": "1.3.15",
    "json3": "~3.2.6",
    "es5-shim": "~2.1.0",
    "angular-resource": "1.3.15",
    "angular-sanitize": "1.3.15",
    "angular-animate": "1.3.15",
    "angular-cookies": "1.3.15",
    "angular-touch": "1.3.15",
    "angular-moment": "~0.6.2",
    "angular-loading-bar": "0.6.0",
    "angular-masonry": "0.11.0",
    "js-cookie": "2.1.3"
  },
  "devDependencies": {
    "angular-mocks": "1.3.15",
    "angular-scenario": "1.3.15"
  }
}

Can anyone help me here to how to proceed ahead.

Thanks, Santosh


Solution

  • Thats because the dependencies you are injecting requires different versions of angularJs. For resolving it, first find a suitable compatible version of angularJs. And then you can add resolutions to the object in your bower.json file and specify the component name & version to automatically resolve the conflict when running bower commands. Like this:

    {
     "name": "test-app",
     "version": "1.1.6",
     "dependencies": {
               "jquery": "2.1.0",
               "jquery-bridget": "*",
         "angular": "1.3.15",
         "json3": "~3.2.6",
         "es5-shim": "~2.1.0",
         "angular-resource": "1.3.15",
         "angular-sanitize": "1.3.15",
         "angular-animate": "1.3.15",
         "angular-cookies": "1.3.15",
         "angular-touch": "1.3.15",
         "angular-moment": "~0.6.2",
         "angular-loading-bar": "0.6.0",
         "angular-masonry": "0.11.0",
         "js-cookie": "2.1.3"
      },
      "devDependencies": {
         "angular-mocks": "1.3.15",
         "angular-scenario": "1.3.15"
      },
      "resolutions": {
         "angular": "1.3.15"
      }
    }