New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Help Wanted: Shims for jQuery independence and Zepto support #5
Comments
A clean way to do things might be to start a very specific, stripped to the core object of methods for the jQuery needs, so as not to disrupt too much of your incredibly clean and clear code. And I think not supporting IE 7 is very wise. One would assume another would not see much difference between your optimized animations vs. those of jQuery on a Widnows XP + IE lte 7 configuration. |
Well said. And, I agree with your suggestion fully. Question is, who's going to do build it? :) If no one else does, I'll attack it in the future. |
I'm going to make a quick skeleton of the |
You are awesome. Excited that you're interested in toying with this. I know a lot of people will appreciate this. I've been asked about jQuery independence multiple times in the last 24 hours. |
Sample prefixes we could use: $Util('<span>').html("$ is old"); _$('<span>').html("_$ is dead"); $_('<span>').html("Long live S!"); |
Minification turns any "multiple-letter identifier" into a single one anyway, so you could just get away with a normal word (similar to how jQuery has both jQuery and $). |
My judgement is sleep deprived. I went with At the moment, it's very primitive and basically can't be used for anything, not even for the "implemented" .offset() method, because I'm not even handling the DOM elements well. 😆 |
Alright, it's getting there. I tried the last version I committed on the playground, and it seems to be working. Further testing will be needed though, obviously, but this is a good start. This is the full list of used jQuery functions, please comment if you've seen more. Done:
Left to do:
|
Just double checking on this, is jquery out of the plugin for good? |
yep |
These jQuery functions need to be stripped out into their own Velocity add-on -- preferably all encapsulated under a new prefix to indicate their connection, but also their differentiation, from their jQuery counterparts:
$.extend()
$.data()
$.queue()
$.dequeue()
$.offset()
$.isPlainObject()
$.isEmptyObject()
The goal would be to separate out these shims into an independent file to be optionally loaded alongside Velocity in production.
If anyone's willing to tackle this, feel free to reach out to me about it. For now, my personal focus is on addressing any bugs that arise so I can ensure Velocity is a reliable long-term replacement for jQuery's $.animate().
The text was updated successfully, but these errors were encountered: