$('something').parents('selectors') lets me move several levels up the DOM at once, versus parent() which unsurprisingly returns the current element’s immediate parent. Unfortunately (though logically), children() does not operate like parents() and instead only returns the element’s immediate children, similar to how parent() works. I’m sure that I could whip up something that would get all appropriate descendants no matter how deep, but I’m wondering if there already is some relatively simple way to do this. Any chance?
$(‘something’).parents(‘selectors’) lets me move several levels up the DOM at once, versus parent() which
Share
Use the find such as
find('selectors')