Skip to content

Commit 6481481

Browse files
committed
Ref gh-240, 1.9 updates for .add()
1 parent 73c0dbf commit 6481481

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

entries/add.xml

+1
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
<desc>Add elements to the set of matched elements.</desc>
3838
<longdesc>
3939
<p>Given a jQuery object that represents a set of DOM elements, the <code>.add()</code> method constructs a new jQuery object from the union of those elements and the ones passed into the method. The argument to <code>.add()</code> can be pretty much anything that <code>$()</code> accepts, including a jQuery selector expression, references to DOM elements, or an HTML snippet.</p>
40+
<p>Do not assume that this method appends the elements to the existing collection in the order they are passed to the <code>.add()</code> method. When all elements are members of the same document, the resulting collection from <code>.add()</code> will be sorted in document order; that is, in order of each element's appearance in the document. If the collection consists of elements from different documents or ones not in any document, the sort order is undefined. To create a jQuery object with elements in a well-defined order, use the <code>$(array_of_DOM_elements)</code> signature.</p>
4041
<p>The updated set of elements can be used in a following (chained) method, or assigned to a variable for later use. For example:</p>
4142
<pre>
4243
<code>

0 commit comments

Comments
 (0)