jQuery 和 Google Maps API v3 的最佳插件?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/4284167/
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
Best plugin for jQuery and Google Maps API v3?
提问by Alex
I've been looking for a jQuery plugin to load a gMaps using Google Maps API v3.
我一直在寻找一个 jQuery 插件来使用 Google Maps API v3 加载 gMaps。
What are the jQuery plugins you use in this case?
在这种情况下,您使用的 jQuery 插件是什么?
At the moment, jMapping is the best I've found:
目前,jMapping 是我发现的最好的:
采纳答案by Benjamin Wohlwend
回答by johansalllarsson
I might be a bit bias here, but I would recommendjquery.ui.map - jQuery Google maps v3 plugin for UI and jQuery mobile, since it can populate a map from microdata, microformats and rdfa, thus search engine friendly :) plus it's small and easy to use.
我在这里可能有点偏见,但我会推荐jquery.ui.map - 用于 UI 和 jQuery mobile 的 jQuery Google maps v3 插件,因为它可以从微数据、微格式和 rdfa 填充地图,因此对搜索引擎友好 :) 加上它小巧且易于使用。
Gmap3 4.1:
Gmap3 4.1:
Positive: Seems to have alot of functions, like it's own clustering (I havn't tested it properly)
正面:似乎有很多功能,就像它自己的聚类一样(我没有正确测试过)
Negative: It's big (29kB) and the syntax is slightly confusing (I havn't tested it properly).
否定:它很大(29kB)并且语法有点混乱(我没有正确测试它)。
Total size: 29kB
总大小:29kB
jMapping 2.1.0:
jMapping 2.1.0:
Positive: Good for SEO and usability since you always have to have an html list present.
正面:有利于 SEO 和可用性,因为您始终必须有一个 html 列表。
Negative: Not using standard metadata and use of data attribute, alot overhead, not flexible, lacking alot of features
负面:不使用标准元数据和使用数据属性,开销很大,不灵活,缺乏很多功能
Total size: 49kB - jMapping 6kB + jQuery metadata 5kB + markermanager 29kB + Styledmarker 9kB
总大小:49kB - jMapping 6kB + jQuery 元数据 5kB + 标记管理器 29kB + Styledmarker 9kB
I wouldn't consider building anything more complex than 'this is my office' or 'parks in our city'.
我不会考虑建造比“这是我的办公室”或“我们城市的公园”更复杂的东西。
goMap 1.3.2:
去地图 1.3.2:
Positive: Kind of easy to use. Better than jMapping when it comes to having more features
正面:有点易于使用。在拥有更多功能方面比 jMapping 更好
Negative: Still lacking alot of features, not flexible
负面:仍然缺乏很多功能,不灵活
Total size: 11kB
总大小:11kB
I would use this over jMapping for more complex implementations, however it seems I'd still have to write alot of native Google maps code.
对于更复杂的实现,我会在 jMapping 上使用它,但是似乎我仍然需要编写大量本地 Google 地图代码。
jquery.ui.map v.3:
jquery.ui.map v.3:
Positive: Easy to use, split into several js files (or one) for your implementation needs. Can read from standardized metadata (microdata, microformats, RDFa) which means it's good for SEO and usability, easy to override any function or add new functions without hacking the core.
正面:易于使用,拆分为多个 js 文件(或一个)以满足您的实现需求。可以从标准化元数据(微数据、微格式、RDFa)中读取,这意味着它有利于 SEO 和可用性,易于覆盖任何功能或添加新功能而无需破解核心。
Negative: It has alot of options, which might add complexity for people not used to the plugin and/or jQuery.
负面:它有很多选项,这可能会增加不习惯插件和/或 jQuery 的人的复杂性。
Total size alt. 1: 4kB - jquery.ui.map.min.full.js (4kB)
总尺寸 alt。1: 4kB - jquery.ui.map.min.full.js (4kB)
Total size alt. 2: 5-7kB - jquery.ui.map.min.full.js (4kB), jquery.ui.rdfa.min.js/jquery.ui.microformat.min.js/jquery.ui.microdata.min.js (1-3kB)
总尺寸 alt。2: 5-7kB - jquery.ui.map.min.full.js (4kB), jquery.ui.rdfa.min.js/jquery.ui.microformat.min.js/jquery.ui.microdata.min.js (1-3kB)
Other jquery google maps plugins can be found here
其他 jquery 谷歌地图插件可以在这里找到