bower ECONFLICT Unable to find suitable version for jquery 错误,即使在添加分辨率后也是如此

bower ECONFLICT Unable to find suitable version for jquery error even after adding resolutions

"dependencies": { 
  "jquery": "~2.1.4", 
  "angular": "~1.5.0",
  ....
  ....
},
"resolutions": {
  "jquery": "~2.1.4",
  "angular": "~1.5.0"
}

bower 安装angular-peity --save

bower angular-peity#* 已缓存 https://github.com/projectweekend/angular-peity.git#0.0.5 bower angular-peity#* 针对 https://github.com/projectweekend/angular-peity.git#* 验证 0.0.5 bower peity#* 已缓存 https://github.com/benpickles/peity.git#3.2.1 bower peity#* 根据 https://github.com/benpickles/peity.git#* 验证 3.2.1 凉亭 jquery#~2.0.3 缓存 https://github.com/jquery/jquery-dist.git#2.0.3 bower jquery#~2.0.3 根据 https://github.com/jquery/jquery-dist.git#~2.0.3 验证 2.0.3 bower jquery#>=1.6 缓存 https://github.com/jquery/jquery-dist.git#3.1.1 bower jquery#>=1.6 针对 https://github.com/jquery/jquery-dist.git#>=1.6 验证 3.1.1 bower jquery#>=1.7 缓存 https://github.com/jquery/jquery-dist.git#3.1.1 bower jquery#>=1.7 针对 https://github.com/jquery/jquery-dist.git#>=1.7 验证 3.1.1 bower jquery#1.9.1 - 3 个缓存 https://github.com/jquery/jquery-dist.git#3.1.1 bower jquery#1.9.1 - 3 根据 https://github.com/jquery/jquery-dist.git#1.9.1 - 3 验证 3.1.1 bower jquery#>=1.4.4 缓存 https://github.com/jquery/jquery-dist.git#3.1.1 bower jquery#>=1.4.4 针对 https://github.com/jquery/jquery-dist.git#>=1.4.4 验证 3.1.1 凉亭 jquery#^2.0.3 缓存 https://github.com/jquery/jquery-dist.git#2.2.4 bower jquery#^2.0.3 根据 https://github.com/jquery/jquery-dist.git#^2.0.3 验证 2.2.4 bower ECONFLICT 无法为 jquery

找到合适的版本

最好的开始方式是

bower cache clean

在那之后

bower install它会问你

Unable to find a suitable version for jquery, please choose one:
1) jquery#exampleversion1 which resolved to 1.5.3 and is required by demo1
2) jquery#^exampleversion2 which resolved to 1.5.3 and is required by app2    
3) jquery#>.examplegversion3 which resolved to 1.5.3 and is required by app3Test

然后你可以输入 !1!2 ,或者任何最适合你需要的。

数字前缀 ! 本质上是将解析块添加到 bower.json 中,但它会让您更好地控制正在发生的事情,它可能会解决您的问题。

我在 Windows 10 上遇到了与 Git Bash 相同的错误 Windows

ECONFLICT Unable to find suitable version for jquery

它不会转到我可以选择选项 !1!2

的部分

对我来说,切换到 Windows PowerShell 解决了问题并运行相同的命令 bower install

我怀疑它与用户权限有关。