Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Passing test case against http://bugs.jquery.com/ticket/12881 #643

wants to merge 1 commit into


None yet
2 participants

dandv commented Nov 12, 2012

http://api.jquery.com/jQuery/ states that "As of jQuery 1.4, the second argument to jQuery() can accept a map consisting of a superset of the properties that can be passed to the .attr() method."

Turns out that actually,

The only HTML you can use with that signature is a simple element with no attributes, such as $("<a/>", { ... }). I strongly recommend you not use the signature at all and used chaining instead.

Zepto behaves better than jQuery in this case. Added a test case to make sure this nice behavior is preserved.


mislav commented Nov 25, 2012

Extra test cases can't hurt! Pulled.

@mislav mislav closed this Nov 25, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment