Skip to content

Commit

Permalink
Merge pull request #1 from wyysf123/wyysf123-patch-1
Browse files Browse the repository at this point in the history
fixed customElements.define error
  • Loading branch information
wyysf123 authored Mar 9, 2022
2 parents 2f71bc9 + 489b56b commit c862364
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/compiler/compile/render_dom/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ export default function dom(

if (component.tag != null) {
body.push(b`
@_customElements.define("${component.tag}", ${name});
!@_customElements.get("${component.tag}") && @_customElements.define("${component.tag}", ${name});
`);
}
} else {
Expand Down

0 comments on commit c862364

Please sign in to comment.