code: private void renderCombinedEventScripts()
      {
          final StringBuilder combinedScript = new StringBuilder();
  
          for (final OnDojoReadyHeaderItem curItem : this.dojoReadyItems) {
              combinedScript.append("\n");
              combinedScript.append(curItem.getJavaScript());
              combinedScript.append(";");
          }
  
          if (combinedScript.length() > 0) {
              super.render(OnDojoReadyHeaderItem.forScript(combinedScript.append("\n").toString()));
          }
      }
docs: Combines all DOM ready and onLoad scripts and renders them as 2 script
  tags.