prettify, sorry for the big ass commit

This commit is contained in:
Olivier Gagnon
2021-09-04 19:09:30 -04:00
parent 3d7cdb4ef9
commit a18bdd6afc
554 changed files with 91615 additions and 66138 deletions
+18 -16
View File
@@ -3,24 +3,26 @@
* @param elem The element to remove.
*/
export function removeElement(elem: Element | null): void {
if (elem === null) {
// tslint:disable-next-line:no-console
console.debug("The element passed into 'removeElement' was null.");
if (elem === null) {
// tslint:disable-next-line:no-console
console.debug("The element passed into 'removeElement' was null.");
return;
}
if (!(elem instanceof Element)) {
// tslint:disable-next-line:no-console
console.debug("The element passed into 'removeElement' was not an instance of an Element.");
return;
}
if (!(elem instanceof Element)) {
// tslint:disable-next-line:no-console
console.debug(
"The element passed into 'removeElement' was not an instance of an Element.",
);
return;
}
return;
}
while (elem.firstChild !== null) {
elem.removeChild(elem.firstChild);
}
while (elem.firstChild !== null) {
elem.removeChild(elem.firstChild);
}
if (elem.parentNode !== null) {
elem.parentNode.removeChild(elem);
}
if (elem.parentNode !== null) {
elem.parentNode.removeChild(elem);
}
}