Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Accept arbitrary objects in $.qsa #321
It's not clear to me from the jQuery docs whether plugins are supposed to do this or not, but, well, they apparently do, so perhaps Zepto can accomodate.
Okay, it turns out this is more complicated than I originally thought, since the plugins also bind and trigger events on the non-DOM objects - so trigger, add, and remove would also need to be modified (they use addEventListener and dispatchEvent now). I've tried modifying but haven't figured out the right way to do it yet.
So maybe this is too significant of a change for now. I'm working around for now.
I don't even know what's going on, but I think if you construct a Zepto instance with non-DOM objects, you can't really expect DOM methods to work for it.
Also, plugins that bind and trigger their own events, especially on non-DOM objects, are simply badly written, so I don't really have great motivation to make Zepto work with them.
Let us know when you have more thoughts on this.