Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/component/matches-selector
Check if an element matches a given selector string
https://github.com/component/matches-selector
Last synced: 12 days ago
JSON representation
Check if an element matches a given selector string
- Host: GitHub
- URL: https://github.com/component/matches-selector
- Owner: component
- Created: 2012-09-05T21:16:03.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2017-08-24T15:24:42.000Z (over 7 years ago)
- Last Synced: 2024-10-30T02:37:24.477Z (about 2 months ago)
- Language: JavaScript
- Size: 33.2 KB
- Stars: 14
- Watchers: 5
- Forks: 24
- Open Issues: 1
-
Metadata Files:
- Readme: Readme.md
- Changelog: History.md
Awesome Lists containing this project
README
# matches-selector
Check if an element matches a given selector.
## Installation
$ component install component/matches-selector
## Example
```js
var matches = require('matches-selector');
matches(el, 'ul li a');
// => true
```## License
MIT