Glossary: JavaScript in the Browser
closest
Also written: closest()
A method that checks an element and then each ancestor, returning the first that matches a selector, or null. It is how a click on a button's inner span is still traced to the button or card.