Skip to content

Commit

Permalink
Merge pull request #534 from riley817/feature/import-js-module
Browse files Browse the repository at this point in the history
Feature/import js module
  • Loading branch information
cg33 authored Nov 26, 2022
2 parents bd0329c + b820389 commit c6bf940
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions template/types/info.go
Original file line number Diff line number Diff line change
Expand Up @@ -1671,6 +1671,10 @@ func (i *InfoPanel) AddJS(js template.JS) *InfoPanel {
return i.addFooterHTML(template.HTML("<script>" + js + "</script>"))
}

func (i *InfoPanel) AddJSModule(js template.JS) *InfoPanel {
return i.addFooterHTML(template.HTML("<script type='module'>" + js + "</script>"))
}

func (i *InfoPanel) addCallback(node context.Node) *InfoPanel {
i.Callbacks = i.Callbacks.AddCallback(node)
return i
Expand Down

0 comments on commit c6bf940

Please sign in to comment.