DEV/DEV4.1/tp4/ex3/modules/loader.js
2024-03-01 15:39:57 +01:00

16 lines
217 B
JavaScript

class loader {
div = null
constructor(node){
this.div = node
}
set(loading){
if (loading)
this.div.classList.add("is-loading")
else
this.div.classList.remove("is-loading")
}
}
export default loader