@barusu/util-blobdeprecated

Util funcs for handling Blob object such as download or create a blob from dataUrl

Usage no npm install needed!

<script type="module">
  import barusuUtilBlob from 'https://cdn.skypack.dev/@barusu/util-blob';
</script>

README

@barusu/util-blob


Install

  • npm

    npm install --save @barusu/util-blob
    
  • yarn

    yarn add @barusu/util-blob
    

Usage

  • convertDataURLToBlob(dataURL: string): Blob: Creates and returns a blob from a data URL (either base64 encoded or not).

  • downloadBlob(blob: Blob, filename: string): void: emit a download task in browser