jQuery 3.2.1 发布了,这个版本包括一些修补程序,用于在 4 天前在 3.2.0 版本中引入的回归。官方也希望可以尽快发布这个补丁程序,以减少在升级时遇到的任何错误。最重要的一点是检索没有显式设置尺寸的内联元素的宽度或高度。现在应该会正常工作。下面提供了完整的更改列表。也可以参阅 3.2.0 的博客帖子以了解修复的错误和改进。
如果尚未升级到 jQuery 3+,请查看 3.0 升级指南。jQuery Migrate 3.0 插件将帮助你识别代码中的兼容性问题。
变更
Core
Ensure jQuery.holdReady is in the right place
Dimensions
Ensure we get proper values for width and height on elements with display “inline”
Event
Ensure trigger data is passed to radio click event handlers
Revert: Trigger checkbox and radio click events identically
Revert: Add radio click triggering tests
下载
https://code.jquery.com/jquery-3.2.1.js
https://code.jquery.com/jquery-3.2.1.min.js
也可从 npm 获取:
npm install jquery@3.2.1
软件详情:http://blog.jquery.com/2017/03/20/jquery-3-2-1-now-available/
来自:开源中国社区

