简体   繁体   English

GwtQuery(gQuery)是否像jQuery这样的跨浏览器库?

[英]Is GwtQuery (gQuery)a cross browser library like jQuery?

Does GwtQuery offer the same browser compatibility as jQuery? GwtQuery是否提供与jQuery相同的浏览器兼容性? If not, what browsers has it been tested with? 如果没有,它已经在哪些浏览器上进行了测试?

  • gQuery(GwtQuery) supports Browser compatibility as jQuery. gQuery(GwtQuery)支持浏览器与jQuery的兼容性。
  • Each browser gets separately compiled JS 每个浏览器获取单独编译的JS

gQuery is an entire rewrite of GWT in jQuery. gQuery是jQuery中GWT的完整重写。

GQuery and jQuery are built around selectors. GQuery和jQuery是围绕选择器构建的。

Both support CSS standard selectors plus extra selectors (:text :password :hidden etc). 两者都支持CSS标准选择器以及额外的选择器(:text:password:hidden等)。

jQuery uses the sizzle engine. jQuery使用sizzle引擎。 A javascript engine which works with any browser and has optimizations per browser. 一个可与任何浏览器一起使用并针对每个浏览器进行优化的JavaScript引擎。

GQuery has optimized engines written in java. GQuery具有使用Java编写的优化引擎。

The more appropriate engine is selected in compile time. 在编译时选择更合适的引擎。

GQuery uses a modified sizzle version for IE6/7 GQuery对IE6 / 7使用了修改后的izzizz版本

GQuery adds compile-time optimizations when using compiled selectors. 使用已编译的选择器时,GQuery添加了编译时优化。

Compiled Selectors 编译选择器

  • Use them with immutable selectors and when selector performance is a goal in your application. 当选择器性能是应用程序的目标时,请将它们与不变的选择器一起使用。

Selectors Performance 选择器性能

  • GQuery in compiled mode produces the faster javascript code to select DOM elements. 编译模式下的GQuery生成更快的JavaScript代码以选择DOM元素。

  • GQuery dynamic selectors are, in most cases, faster or equal than any other library. 在大多数情况下,GQuery动态选择器比任何其他库都快或相等。

Events 活动

  • GQuery provides methods for assigning event in a cross-browser way. GQuery提供了用于以跨浏览器方式分配事件的方法。
  • GQuery event system is compatible with Gwt. GQuery事件系统与Gwt兼容。
  • issues: – When Gwt detaches a widget, events added via GQuery are lost. 问题:– Gwt分离小部件时,通过GQuery添加的事件将丢失。

References: 参考文献:

https://code.google.com/p/gwtquery/wiki/GettingStarted http://vinaytechs.blogspot.in/2009/09/gwtquery-jquery-in-gwt.html https://code.google.com/p/gwtquery/wiki/GettingStarted http://vinaytechs.blogspot.in/2009/09/gwtquery-jquery-in-gwt.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM