text: /*eslint-disable */
  
  // helper function to convert URL to blob (TODO check IE compatibility?)
  export default function pngDataURIToBlob(dataURI) {
      // convert base64/URLEncoded data component to raw binary data held in a string
      var byteString;
      if (dataURI.split(',')[0].indexOf('base64') >= 0)
          byteString = atob(dataURI.split(',')[1]);
      else
          byteString = unescape(dataURI.split(',')[1]);
  
      // separate out the mime component
      var mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0];
  
      // write the bytes of the string to a typed array
      var ia = new Uint8Array(byteString.length);
      for (var i = 0; i < byteString.length; i++) {
          ia[i] = byteString.charCodeAt(i);
      }
  
      if (mimeString !== "image/png") {
        throw new Error("Filetype is not supported! " + mimeString);
      }
  
      console.log(mimeString);
  
      return new Blob([ia], {type:mimeString});
  }
  
  /*eslint-enable */
  