jquery function to remove class code example
Example: js remove class
const removeClass = (element, name) => {
const pattern = new RegExp('(?:^|\\s)'+ name + '(?:\\s|$)', 'g');
element.className = element.className.replace(pattern, "");
};
const removeClass = (element, name) => {
const pattern = new RegExp('(?:^|\\s)'+ name + '(?:\\s|$)', 'g');
element.className = element.className.replace(pattern, "");
};