code: function parser () {
    // When the form is submitted, parse the Swagger API
    form.form.on("submit", function (event) {
      event.preventDefault();
      parseSwagger();
    });
  
    // When the "x" button is clicked, discard the results
    $("#clear").on("click", function () {
      swaggerParser = null;
      editors.clearResults();
      analytics.trackEvent("results", "clear");
    });
  }
docs: Adds event handlers to trigger Swagger Parser methods