Hi, don't you think makeArray should be a bit smarter?
Instead of doing $.makeArray( foo
[] ) all the time, it should handle that internally.
$.fn.setArray does a lot of checks that IMO, belong to $.makeArray.
By improving it, you can remove those pesky checks from many places.
This version handles pretty much any kind of argument, without using too many checks.
I know that internal functions have to as fast as possible, I optimized this as much as I could, but well, in the end, it's up to you (core team).
Attachments
Change History
Download in other formats:
|