Tiny zero dependency helper module to check if element(s) have a particular class
npm install element-hasclassTiny zero dependency helper module to check if element(s) have a particular class
This emulates jQuery's hasClass behaviour: it works for multiple elements, and even works in awful browsers.
``javascript`
hasClass(elements, 'class-to-check');
Grab from NPM
``
npm install element-hasclass
And import it
`javascript`
import hasClass from 'element-hasclass';
Or grab the minified JavaScript from unpkg
`html``