code: protected void includeChartJavascript(final IHeaderResponse response, final ChartConfiguration options,
                                            final JsonRenderer renderer, final String markupId) {
          String chartVarname = this.chart.getJavaScriptVarName();
          String optionsVarname = markupId + "Options";
          String contextVarname = markupId + "ctx";
          String jsonOptions = renderer.toJson(options);
          
          if(options.getOptionalJavascript() == null) {
              response.render(OnDomReadyHeaderItem.forScript(MessageFormat.format(
                      "var {0} = {1};"
                      + "var {3} = document.getElementById(\"{4}\").getContext(\"2d\");"
                      + " window.{2} = new Chart({3},{0});",
                      optionsVarname, jsonOptions,chartVarname,contextVarname,markupId)));
          }
          else {
          	String optionalJavascript = options.getOptionalJavascript();
          	String replacedVariablesInOptionalJavascript = optionalJavascript.replace("{0}", contextVarname);
              response.render(OnDomReadyHeaderItem.forScript(MessageFormat.format(
                      "{5} var {0} = {1};"
                      + "var {3} = document.getElementById(\"{4}\").getContext(\"2d\");"
                      + " window.{2} = new Chart({3},{0});",
                      optionsVarname, jsonOptions,chartVarname,contextVarname,markupId,replacedVariablesInOptionalJavascript)));
          }
      }
docs: Includes the javascript that calls the Highcharts library to visualize the
  chart.
  
  @param response the Wicket HeaderResponse
  @param options  the options containing the data to display
  @param renderer the JsonRenderer responsible for rendering the options
  @param markupId the DOM ID of the chart component.