[-] Remove the unnecessary clz shorthand

This commit is contained in:
Azalea
2024-03-02 19:55:52 -05:00
parent c2fef3fa25
commit dfd8d1b0c9
5 changed files with 10 additions and 24 deletions

View File

@@ -88,16 +88,4 @@ export const CHARTJS_OPT: ChartOptions<'line'> = {
intersect: false
}
},
}
/**
* Convert object keys to classes depending on their values
*
* @param obj Dictionary object {classname: truthy}
* @param others Other classes to add
*/
export function clz(obj: any, others?: string) {
let cls = Object.keys(obj).filter(key => obj[key]).join(' ')
if (others) cls += ' ' + others
return cls
}
}