title: What is a Blob used in Jquery
body: <p>I came across <code>blob</code> while searching some stuff in jQuery. Googled about it but could not exactly figure out what kind of concept it is.</p>
  
  <p>I found this code for downloading a pdf file through Ajax.</p>
  
  <pre><code>$.ajax({
      method: 'GET',  
      dataType: 'blob',
      data: { report_type: report_type, start_date: start_date, end_date: end_date, date_type: date_type },
      url: '/reports/generate_pdf.pdf',
          success: function(data) {
              var blob=new Blob([data]);
              var link=document.createElement('a');
              link.href=window.URL.createObjectURL(blob);
  
              link.download="Report_"+new Date()+".pdf";
              link.click();
              console.log("pdf printed");
          }
  });
  </code></pre>
  
  <p>This code is working fine but printing empty pdf without the content either static or dynamic. But with a strange behaviour. I.e. if the dynamic data calculated is too big, it is generating multiple pages.</p>
  
  <p>I just want to figure out the concept of <code>blob</code> so that I can figure out myself what this piece of code is doing and how does <code>blob</code> work.</p>
  
  <p>Any proper guide or help would be really appreciated. Thanks in advance!</p>