feature: vor und nachteile

This commit is contained in:
Hikyu
2026-05-31 13:54:31 +02:00
parent 552a947a1c
commit e3dad17446
23270 changed files with 3024794 additions and 200 deletions
+19
View File
@@ -0,0 +1,19 @@
/**
* Get boolean customisation value from attribute
*/
function toBoolean(name, value, defaultValue) {
switch (typeof value) {
case "boolean": return value;
case "number": return !!value;
case "string": switch (value.toLowerCase()) {
case "1":
case "true":
case name.toLowerCase(): return true;
case "0":
case "false":
case "": return false;
}
}
return defaultValue;
}
export { toBoolean };