Closed
Description
I the .prev
docs the description is
Get the immediately preceding sibling of each element in the set of matched elements,
optionally filtered by a selector.
I took this to mean that, given a selector, .prev
would traverse back through sibling elements until it found one matching that selector. See also http://stackoverflow.com/questions/5452917/jquery-prevselector-not-working.
In the .next
docs, however, it is far more clear:
... it retrieves the next sibling only if it matches that selector.
Metadata
Metadata
Assignees
Labels
No labels