operateclass
v1.0.7
Published
you can add className or remove className at dom
Downloads
16
Maintainers
Readme
operateclass
npm install operateclass --save
// when you want to add className at dom
import {addClass} from 'operateclass'
// el is the dom
addClass(el, className)
// when you want to remove className from dom
import {removeClass} from 'operateclass'
// el is the dom
removeClass(el, className)
// Whether there is such a class
import {hasClass} from 'operateclass'
// el is the dom
hasClass(el, className)
let operateclass = require('operateclass')
// el is the dom
operateclass.addClass(el, className)
operateclass.removeClass(el, className)
operateclass.hasClass(el, className)