Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
thescientist13 committed Apr 10, 2024
1 parent 3d5d4aa commit 00b63eb
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/wcc.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ async function renderComponentRoots(tree, definitions) {
console.log('elementHtml', { elementHtml });
console.log('elementTree', { elementTree });
console.log('elementTree.childNodes', elementTree.childNodes);
console.log('node.childNodes', node.childNodes)
console.log('node.childNodes', node.childNodes);

node.childNodes = node.childNodes.length === 0 && elementTree.childNodes > 0 && !hasShadow
node.childNodes = node.childNodes.length === 0 && hasLight > 0 && !hasShadow
? elementTree.childNodes
: hasShadow
? [...elementTree.childNodes, ...node.childNodes]
Expand Down Expand Up @@ -175,7 +175,7 @@ async function initializeCustomElement(elementURL, tagName, node = {}, definitio
if (attrs.length > 0) {
attrs.forEach(attr => {
innerHTML += ` ${attr.name}="${attr.value}"`;
})
});
}

innerHTML += '>';
Expand All @@ -184,15 +184,15 @@ async function initializeCustomElement(elementURL, tagName, node = {}, definitio
if (c.nodeName === '#text') {
innerHTML += c.value;
}
})
});

innerHTML += `</${nodeName}>`;
}
})
});

console.log({ innerHTML });
elementInstance.innerHTML = innerHTML;
console.log('=================')
console.log('=================');

attrs.forEach((attr) => {
elementInstance.setAttribute(attr.name, attr.value);
Expand Down

0 comments on commit 00b63eb

Please sign in to comment.