title: Initiating the download of a file blob in Safari
body: <p><em>Let me preface by saying I have seen many questions in a similar vein here, but none with this same scenario that provide a working solution.</em></p>
  
  <p>I am generating a PDF from a canvas element via javascript. When all is said and done, I have the PDF saved in a variable as a raw-encoded blob with a type of 'application/pdf'. In every major browser - Internet Explorer, Mozilla Firefox, Google Chrome - the following code snippet is enough to initiate the download:</p>
  
  <pre><code>saveAs(blob, 'filename.pdf');
  </code></pre>
  
  <p>However, Safari does not do anything. I have tried using FileReader's <strong>readAsDataURL</strong> method as well as <strong>URL.createObjectURL</strong> and the webkit vendor-specific api for it, then using window.open() to open a new tab/window with that as the contents.</p>
  
  <p>I am looking for any solution that would allow me to initiate this download directly for my Safari users without having to pass the data to a server first.</p>