by IgorPartola · 16y ago · 0 comments
So don't do it. It's not required.
> Concatenating a bunch of things together to make a selector
This is semi-valid and using the jQuery.filter() function helps a bit. Overall though, it's not a huge problem, IMHO. Just put together the selector incrementally. Likely you need bits of that selector elsewhere anyways.
> Going over the top with chaining
I've written some complex code using jQuery and none of it had a chain as long as your example. Still don't see how this is jQuery's fault.
> Not caching collections
Then cache them. How is jQuery preventing you from doing this?
> HTML
This is just runs faster. When performance is critical, I find it acceptable to do this.
The author is pointing out coding practices that cause him to suspect that others' jQuery code may not be very good.
That's exactly what I thought ... until I read the article. Your intent seems pretty clear to me; but if a lot of people are misunderstanding you, that's a good sign you need to change the message to address the widespread confusion.
1. Use a slow js library framework abstraction layer! yay!
2. Speed it back up a bit by using ugly messes of html strings