From 7e18aefee435de4cfea94b9f284e4b418caa872f Mon Sep 17 00:00:00 2001 From: Aurelio De Rosa Date: Tue, 20 Dec 2016 15:45:23 +0000 Subject: [PATCH] find(): Mention support for selectors starting with > Fixes gh-973 --- entries/find.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entries/find.xml b/entries/find.xml index 0a080a05..c6a32e84 100644 --- a/entries/find.xml +++ b/entries/find.xml @@ -18,7 +18,7 @@ Get the descendants of each element in the current set of matched elements, filtered by a selector, jQuery object, or element.

Given a jQuery object that represents a set of DOM elements, the .find() method allows us to search through the descendants of these elements in the DOM tree and construct a new jQuery object from the matching elements. The .find() and .children() methods are similar, except that the latter only travels a single level down the DOM tree.

-

The first signature for the .find()method accepts a selector expression of the same type that we can pass to the $() function. The elements will be filtered by testing whether they match this selector.

+

The first signature for the .find()method accepts a selector expression of the same type that we can pass to the $() function. The elements will be filtered by testing whether they match this selector. The expressions allowed include selectors like > p which will find all the paragraphs that are children of the elements in the jQuery object.

Consider a page with a basic nested list on it:


 <ul class="level-1">