{"dist":{"shasum":"26da6f80b3e0e17e71f80f12782819e9f653495c","tarball":"https://registry.npmjs.org/closest/-/closest-0.0.1.tgz","integrity":"sha512-HafRXTAiWp5nf6kxOy2EoIGSsJMn0zew9E5zp3Dy/8CXdp8GvVjZn1TSMEVdDxSP/acXZcWJWiIgF83Di7M1Ew==","signatures":[{"sig":"MEYCIQDZw7bOx1zMxwKuIvPKnySwJE9zzdC6UyX/kSgZJwvkZQIhAL7foDhljnbHQf4Vy9wukaIVIWv9izklWUW8Nu1CBxFu","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"name":"closest","_from":".","author":{"name":"Jonathan Ong"},"readme":"# Closest\r\n\r\nSimilar to jQuery's `$.fn.closest` and `$.fn.parents`.\r\nFinds the closest parent that matches a selector.\r\n\r\n## Installation\r\n\r\n    $ npm install closest\r\n\r\n## API\r\n\r\n### `closest(element, selector, checkSelf)`\r\n\r\n* element - will check this elements parents\r\n* selector - CSS selector to match parents\r\n* checkSelf - check `element`.\r\n  If falsey, will begin with `element.parentNode` and is synonymous to `$.fn.parents`.\r\n  Otherwise, it's `$.fn.closest`.\r\n\r\nExample:\r\n\r\n```javascript\r\nvar closest = require('cosest');\r\n\r\nclosest(document.body, 'html') === document.documentElement\r\nclosest(document.body, 'body', true) === document.body\r\nclosest(document.documentElement, 'html') == null\r\n```\r\n\r\n## License\r\n\r\n  MIT\r\n","license":"MIT","_npmUser":{"name":"forbeslindesay","email":"forbes@lindesay.co.uk"},"keywords":["browserify","CSS","selector","closest","parents","jquery"],"repository":{"url":"https://github.com/ForbesLindesay/closest.git","type":"git"},"_npmVersion":"1.2.10","description":"Find the closest parent that matches a selector.","maintainers":[{"name":"forbeslindesay","email":"forbes@lindesay.co.uk"}],"dependencies":{"matches-selector":"0.0.1"},"readmeFilename":"README.md","_id":"closest@0.0.1","version":"0.0.1"}