title: Convert blob to pdf file
body: <p>Using react-pdf's BlobProvider, I'm trying to store the file to state. Here's what I tried:</p>
  <pre><code> MyDocument = () =&gt; {
          return (
              &lt;Document&gt;
                  &lt;Page size=&quot;A4&quot; style={stylez.page}&gt;
                      &lt;View style={stylez.section}&gt;
                          &lt;Text&gt;Section TesterYo&lt;/Text&gt;
                      &lt;/View&gt;
                      &lt;View style={stylez.section}&gt;
                          &lt;Text&gt;Section #2&lt;/Text&gt;
                      &lt;/View&gt;
                  &lt;/Page&gt;
              &lt;/Document&gt;
          )
      }
  
   LoadPdf = () =&gt; {
          let myPdf = &lt;BlobProvider document={this.MyDocument}/&gt;
          var file = new File([myPdf], 'filename.pdf', { type: 'application/pdf', lastModified:Date.now()});
  
  
          this.setState({ files: [...this.state.files, file] }, () =&gt; console.log(this.state))
   }
  </code></pre>
  <p>When downloaded this provides a damaged pdf.</p>