title: I want to achieve "new File()" JS function in React native, how can I do this?
body: <p>I want to upload an image file after encoding it , by implement <em><strong>&quot;new File()&quot;</strong></em> function that is shown in the given JS Code into react native, how can i achieve that?</p>
  <pre><code>dataURLtoFile() {
        mime = this.state.imageResponce.type,
  
      let bstr = atob(this.state.imageResponce.base64),
        n = bstr.length,
        u8arr = new Uint8Array(n);
     
      while (n--) {
        u8arr[n] = bstr.charCodeAt(n);
      }
      return new File([u8arr], fileName, { type: mime });
    }
  </code></pre>