MCPcopy Index your code
hub / github.com/monkeytypegame/monkeytype / removeClass

Method removeClass

frontend/src/ts/utils/dom.ts:298–310  ·  view source on GitHub ↗

* Remove a class from the element

(className: string | string[])

Source from the content-addressed store, hash-verified

296 * Remove a class from the element
297 */
298 removeClass(className: string | string[]): this {
299 if (Array.isArray(className)) {
300 this.native.classList.remove(...className);
301 } else {
302 if (className.includes(" ")) {
303 return this.removeClass(
304 className.split(" ").filter((cn) => cn.length > 0),
305 );
306 }
307 this.native.classList.remove(className);
308 }
309 return this;
310 }
311
312 /**
313 * Check if the element has a class

Callers 15

showMethod · 0.95
changeFunction · 0.45
applyFunction · 0.45
applyCustomBackgroundFunction · 0.45
submitFunction · 0.45
updateActiveButtonsFunction · 0.45
updateUIFunction · 0.45
doSortMethod · 0.45
removeClassMethod · 0.45
updateTabsFunction · 0.45
hideFunction · 0.45

Calls 1

removeMethod · 0.45

Tested by

no test coverage detected