Functions / Traversing
Traversing
DOM traversing. 5 snippets.
- Get closest element by selector
$.closest() - Get parent element node
$.parent(), $.parents() - Get siblings of an element
$.siblings(), $.next(), $.nextAll(), $.prev, $.prevAll() - Match element selector
$.is() - Select the children of an element
$.children()
The other groups: