Skip to content

Commit 6142f86

Browse files
committed
jQuery.prev: Clarified its behavior
Fixes gh-861 Closes gh-873
1 parent 5f39705 commit 6142f86

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

entries/prev.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<desc>A string containing a selector expression to match elements against.</desc>
88
</argument>
99
</signature>
10-
<desc>Get the immediately preceding sibling of each element in the set of matched elements, optionally filtered by a selector.</desc>
10+
<desc>Get the immediately preceding sibling of each element in the set of matched elements. If a selector is provided, it retrieves the previous sibling only if it matches that selector.</desc>
1111
<longdesc>
1212
<p>Given a jQuery object that represents a set of DOM elements, the <code>.prev()</code> method searches for the predecessor of each of these elements in the DOM tree and constructs a new jQuery object from the matching elements.</p>
1313
<p>The method optionally accepts a selector expression of the same type that can be passed to the <code>$()</code> function. If the selector is supplied, the preceding element will be filtered by testing whether it match the selector.</p>

0 commit comments

Comments
 (0)