Skip to content

Commit

Permalink
fix: Fix custom element define error (#472)
Browse files Browse the repository at this point in the history
  • Loading branch information
pkissling authored Nov 19, 2024
1 parent 5bc9888 commit 722fb76
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/action-handler-directive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,9 @@ class ActionHandler extends HTMLElement implements ActionHandler {
}
}

customElements.define('action-handler-clock-weather', ActionHandler)
if (!customElements.get('action-handler-clock-weather')) {
customElements.define('action-handler-clock-weather', ActionHandler)
}

const getActionHandler = (): ActionHandler => {
const body = document.body
Expand Down

0 comments on commit 722fb76

Please sign in to comment.