1.0.0 • Published 9 years ago
zap-base-dom-selector v1.0.0
zap-base-dom-selector 
just translating (and testing) some old code to ES6, nothing to see here ;-)
Install
$ npm install zap-base-dom-selector
Usage
import {
$,
$$,
getNext,
getParent,
getParents,
} from 'zap-base-dom-selector';
$
const element = $('.selector');
const elementInsideElement = $('.selector', element);
$$
const elements = $$('.selector');
const elementsInsideElement = $$('.selector', element);
getNext
const nextElement = getNext(element);
getParent
const parent = getParent(element);
const specificParent = getParent(element, '.selector');
getParents
const parents = getParents(element);
const specificParents = getParents(element, '.selector');