title: Export HTML + CSS to PDF using Javascript
body: <p>I want to export a part of my html code to pdf, for this I am using the following code : </p>
  
  <pre><code>&lt;script language = "JAVASCRIPT"&gt;
  var doc = new jsPDF();
  var specialElementHandlers = {
      '#editor': function (element, renderer) {
      return true;
      }
  };
  $('#download').click(function () {
      doc.fromHTML($('#mytable').html(), 15, 15, {
      'width': 170,
          'elementHandlers': specialElementHandlers
      });
      doc.save('sample-file.pdf');
  });
  &lt;/script&gt;
  </code></pre>
  
  <p>but it doesn't support CSS .. how can I export it with its style ?</p>