BlobByteSource constructor
BlobByteSource(
- JSObject blob
Wraps blob, which must be a JS Blob (a File is one) — throws
ArgumentError otherwise. Takes a plain JSObject so any binding
works, e.g. package:web's File/Blob.
Implementation
BlobByteSource(JSObject blob) : _blob = _Blob._(blob) {
if (!blob.instanceOfString('Blob')) {
throw ArgumentError.value(blob, 'blob', 'is not a JS Blob or File');
}
}