[英]Using select2 plugin with Zepto
The problem 问题
For my project I use Zepto, but I would like to use the select2 plugin for my select input elements. 对于我的项目,我使用Zepto,但是我想对我的选择输入元素使用select2插件 。 According to this issue this pull request it should be possibel, yet I couldn't manage to do it.
根据这个问题, 这个拉取请求应该是possibel,但是我无法做到。 I usually get the error
"jQuery not defined"
我通常会收到错误
"jQuery not defined"
What I have 我有的
What I tried 我尝试了什么
Anyone else encountered this problem before or know how to solve it? 其他人之前遇到过此问题,还是知道如何解决? It would be greatly appreciated.
这将不胜感激。 Thanks.
谢谢。
Soo. 洙。 I posted the question to GitHub as an issue, and the creator of the plugin Igor Vaynberg said that I misunderstood the linked issues, as they didn't mean select2 woud support Zepto, they only meant it will be easier to support, if it will be supported some time in the future.
我将问题作为问题发布到GitHub,并且插件的创建者Igor Vaynberg说我误解了链接的问题,因为它们并不意味着select2将支持Zepto,它们只是意味着它将更容易支持。在将来的某个时间得到支持。
For Igor's answer see this comment . 有关Igor的答案,请参阅此评论 。 I might try and implement this myself, if my time permits it, and if I do I will edit this answer also.
如果时间允许,我可能会自己尝试实施此方法,如果可以,我还将编辑此答案。
如果要使用实际上支持Zepto.js的选择, 则可能有兴趣尝试选择: https ://arendjr.github.io/selectivity/
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.