0.0.1 • Published 10 years ago

bloody-matches v0.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
10 years ago

matches

browser support

matches selectors for every browser who supports querySelectorAll

install

$ npm install bloody-matches

require

var matches = require("bloody-matches")

api

matches(selector, element) > boolean

checks if element matches the given selector string.

selector as first argument has been chosen for simpler use of partial/curry.

example

var isAction = curry(matches, ".js-Action")

if(isAction(target)) {
  target.focus()
}
0.0.1

10 years ago

0.0.0

10 years ago