[warnings-ng] Un-inline JavaScript in IssuesChartPortlet/portlet.jelly

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      Culprit

      https://github.com/jenkinsci/warnings-ng-plugin/blob/e659c7ada2792573a475e50242ef4c9d9bdb9b85/plugin/src/main/resources/io/jenkins/plugins/analysis/core/portlets/IssuesChartPortlet/portlet.jelly#L18-L24

      Solution

      Use st:bind with var attribute to define a global variable, which can then be accessed from JavaScript. Use data attributes with e.g. span element to pass whatever other data is needed.
      (No docs exist AFAICT? Perhaps we could improve here )

            Assignee:
            Yaroslav Afenkin
            Reporter:
            Yaroslav Afenkin
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: