switchery
switchery copied to clipboard
Added several practical methods
Switchery.prototype.check = function () {
this.setStatus(true);
};
Switchery.prototype.uncheck = function () {
this.setStatus(false);
};
Switchery.prototype.toggleStatus = function () {
this.setStatus(this.isChecked());
};
Switchery.prototype.setStatus = function (status) {
this.element.checked = !!status;
this.setPosition(true);
};