https://github.com/matype/has-css-combinator
Check if a selector has combinator
https://github.com/matype/has-css-combinator
Last synced: 11 months ago
JSON representation
Check if a selector has combinator
- Host: GitHub
- URL: https://github.com/matype/has-css-combinator
- Owner: matype
- License: other
- Created: 2015-07-31T21:59:09.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2015-07-31T22:17:56.000Z (almost 11 years ago)
- Last Synced: 2025-08-09T07:41:37.330Z (12 months ago)
- Language: JavaScript
- Size: 113 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- Changelog: changelog.md
- License: LICENSE
Awesome Lists containing this project
README
# has-css-combinator [](https://travis-ci.org/morishitter/has-css-combinator)
Check if a selector has combinator.
## Installation
```shell
$ npm install has-css-combinator
```
## Usage
```js
var hasCombinator = require('has-css-combinator')
hasCombinator('.foo+.bar') // true
hasCombinator('.foo + .bar') // true
hasCombinator('.foo ~ .bar') // true
hasCombinator('.foo > .bar') // true
hasCombinator('.foo') // false
hasCombinator('p.foo') // false
```
## License
The MIT License (MIT)
Copyright (c) 2015 Masaaki Morishita