Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

how to convert string into blob in javascript

const str2blob = txt => new Blob([txt]);
Comment

js string to blob

In order to extract data from a Blob, you need a FileReader.

var reader = new FileReader();
reader.onload = function() {
    alert(reader.result);
}
reader.readAsText(blob);
Comment

PREVIOUS NEXT
Code Example
Javascript :: jquery remove link href 
Javascript :: Program for factorial of a number in javascript 
Javascript :: es6 remove empty property from object 
Javascript :: radio button onclick jquery 
Javascript :: js add more text to element 
Javascript :: ERESOLVE unable to resolve dependency tree Found: react@17.0.2 Could not resolve dependency: react native paper 
Javascript :: getting form values in javascript 
Javascript :: regex for check if string is only empty or whitespace javascript 
Javascript :: logout user firebase 
Javascript :: how to print in jsp 
Javascript :: print placeholder value js 
Javascript :: uncaught evalerror: refused to evaluate a string as javascript because 
Javascript :: credit card regex 
Javascript :: jquery event keycode 
Javascript :: js get json keys 
Javascript :: check if function javascript 
Javascript :: mil to km javascript 
Javascript :: share link to whatsapp javascript 
Javascript :: send form data using fetch 
Javascript :: js random word generator 
Javascript :: Array Pagination in JS 
Javascript :: mongoose virtuals 
Javascript :: on function change body background image 
Javascript :: array.find is not a function 
Javascript :: aos animation angular 
Javascript :: package.json set environment variables 
Javascript :: today date js 
Javascript :: express-ejs-layouts install 
Javascript :: create react app cmd 
Javascript :: how to put text in the center react native 
ADD CONTENT
Topic
Content
Source link
Name
6+6 =