我有一個aspnet核心1.0項目VS內鮑爾問題。我bower.json是這個鮑爾VS2015.3下載錯誤的版本
{
"name": "asp.net",
"private": true,
"dependencies": {
"bootstrap": "3.3.6",
"jquery": "2.2.4",
"jquery-validation": "1.14.0",
"jquery-validation-unobtrusive": "3.2.6"
}
}
但是,當我去那個涼亭下載庫我發現jQuery是V3.1.0
/*eslint-disable no-unused-vars*/
/*!
* jQuery JavaScript Library v3.1.0
* https://jquery.com/
*
* Includes Sizzle.js
* https://sizzlejs.com/
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license
* https://jquery.org/license
*
* Date: 2016-07-07T21:44Z
*/
我認爲這是我的機器,但它發生在三臺不同的機器上。難道我做錯了什麼??
編輯: 我試着用這樣的:
{
"name": "asp.net",
"private": true,
"dependencies": {
"jquery": "~2.2.4"
},
"resolutions": {
"jquery": "<=2.2.4"
}
}
在bower.json配置的這隻包是jQuery和仍然安裝的jQuery 3.0.1。爲什麼涼亭這樣做? npm/bower的輸出窗口顯示:
PATH =。\ node_modules.bin; C:\ Program Files(x86)\ Microsoft Visual Studio 14.0 \ Web \ External;%PATH%; C:\ Program Files (x86)\ Microsoft Visual Studio 14.0 \ Web \ External \ git 「C:\ Program Files(x86)\ Microsoft Visual Studio 14.0 \ Web \ External \ Bower.cmd」install --force-latest
bower jquery #〜2.2.4緩存https://github.com/jquery/jquery-dist.git#2.2.4
涼亭的jQuery#〜2.2.4驗證2.2.4對https://github.com/jquery/jquery-dist.git#~2.2.4
涼亭jQuery的超分辨率不必要的分辨率:jQuery的#< = 2.2.4
涼亭的jQuery#〜2.2.4中安裝jQuery 2.2.4#
的jQuery 2.2.4#的wwwroot \涼亭\ jQuery的
你是否在正確的文件夾找?鮑爾可能會安裝到一個不同的文件夾比你想象的... –
是的,我正在看正確的文件夾。我配置了一個不同的文件夾。我也嘗試過使用默認項目,它具有相同的行爲 – snekkke
哦,我剛剛看到了一些......'--force-latest'被附加到你的bower命令中,所以它正是這樣做的。視覺工作室的某處可能會有這樣的設置。我沒有在我面前,但我會尋找工具>選項中的涼亭設置...可能在Web下,然後是關於包的東西。 –