readAsDataURL method
Reads a File or Blob object into memory as a data URL string. The FileReaderSync object is only available within WebWorkers.
![]() |
Syntax
var dataUrl = FileReaderSync.readAsDataURL(object);Parameters
- object [in]
-
Type: Blob or File
- dataUrl [out, retval]
-
Type: dataUrl
Remarks
This method synchronously reads the contents of the specified File or Blob. When the read operation is complete, the readyState property is set to DONE and the onloadend event is fired. The method will return a data URL string that encodes the data that was read.
See also
Show:
