twitter bootstrap 3 jquery 最低版本

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/18891829/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-26 22:42:55  来源:igfitidea点击:

twitter bootstrap 3 jquery minimum version

jquerytwitter-bootstraptwitter-bootstrap-3

提问by werva

What is the Minimumversion of jqueryand jquery-uito use with Twitter bootstrap 3? I have not found any documentation about that.

什么是最低版本jqueryjquery-ui与之一起使用Twitter bootstrap 3?我还没有找到任何关于此的文档。

回答by Max

I've just found this page on Bootstrap 3 "Getting Started" section.

我刚刚在 Bootstrap 3“入门”部分找到了这个页面。

For Bootstrap 3 there are dependencies on JQuery set to version 1.9.0 or higher

对于 Bootstrap 3,对 JQuery 的依赖设置为 1.9.0 或更高版本

http://getbootstrap.com/getting-started/#whats-included

http://getbootstrap.com/getting-started/#whats-included

There you can find a link to their Bower file hosted on GitHub where is clearly written the minimum version of JQuery required by Bootstarp 3.0.2

在那里你可以找到他们在 GitHub 上托管的 Bower 文件的链接,其中清楚地写了 Bootstarp 3.0.2 所需的 JQuery 的最低版本

回答by Leo

I'm putting this here because the last answer is from 2014:

我把它放在这里是因为最后一个答案是 2014 年的:

I have bootstrap version 3.3.6, and if I update to JQuery 3.3.1 this error message appears in the console:

我有引导程序版本 3.3.6,如果我更新到 JQuery 3.3.1,控制台中会出现此错误消息:

Uncaught Error: Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3
at bootstrap.min.js:6
at bootstrap.min.js:6

So lower than version 3, but higher than version 1.9.1 is fine, I just checked that and installed the latest 2.x version of JQuery, which can be found here: https://code.jquery.com/

所以低于版本 3,但高于版本 1.9.1 很好,我只是检查并安装了最新的 2.x 版本的 JQuery,可以在这里找到:https: //code.jquery.com/

The one offered there is: jQuery Core 2.2.4

提供的一个是:jQuery Core 2.2.4

Which just works fine with bootstrap version 3.3.6, and should be ok with version 3.3.7 officialy out.

这在 bootstrap 3.3.6 版上运行良好,在 3.3.7 版正式发布时应该没问题。

回答by Saqib Shakil

Bootstrap 3.1.1 requires Jquery 1.9.1 according to

Bootstrap 3.1.1 需要 Jquery 1.9.1 根据

Plugin dependencies Some plugins and CSS components depend on other plugins. If you include plugins individually, make sure to check for these dependencies in the docs. Also note that all plugins depend on jQuery (this means jQuery must be included before the plugin files). Consult our bower.json to see which versions of jQuery are supported. link to bower.json https://github.com/twbs/bootstrap/blob/v3.3.1/bower.json

插件依赖 一些插件和 CSS 组件依赖于其他插件。如果您单独包含插件,请确保在文档中检查这些依赖项。另请注意,所有插件都依赖于 jQuery(这意味着 jQuery 必须包含在插件文件之前)。请查阅我们的 bower.json 以查看支持哪些 jQuery 版本。链接到 bower.json https://github.com/twbs/bootstrap/blob/v3.3.1/bower.json

回答by kwyjibear

I don't think anyone has actually tested Bootstrap 3 with different versions of jQuery.

我认为没有人实际使用不同版本的 jQuery 测试过 Bootstrap 3。

I was using jQuery 1.3 when I tried to add a Bootstrap carousel. It didn't work. So I upgraded to 1.10 and it worked. (I didn't go to 2.x because it doesn't support IE8 which I need.)

当我尝试添加 Bootstrap 轮播时,我使用的是 jQuery 1.3。它没有用。所以我升级到 1.10 并且成功了。(我没有去 2.x 因为它不支持我需要的 IE8。)

Unfortunately I now have to update other JS code because it's using .live which is deprecated.

不幸的是,我现在必须更新其他 JS 代码,因为它使用的是已弃用的 .live。

回答by chris

On their official website they uses version 1.10.2.

在他们的官方网站上,他们使用版本 1.10.2。