Liking cljdoc? Tell your friends :D

web.files.Blob

A Blob object represents a file-like object of immutable, raw Blobs represent data that isn't necessarily in a JavaScript-native The web.files.File interface is based on Blob, inheriting blob and expanding it to support files on the user's system.

A Blob object represents a file-like object of immutable, raw
Blobs represent data that isn't necessarily in a JavaScript-native
The `web.files.File` interface is based on Blob, inheriting blob
and expanding it to support files on the user's system.
raw docstring

array-buffercljs

(array-buffer this & args)

Method.

[Experimental]

The arrayBuffer() method of the web.files.Blob interface is to read the contents of a Blob as binary data. It returns a promise resolves with an js.ArrayBuffer.

blob.arrayBuffer().then(function (buffer) { // do something with buffer });

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/arrayBuffer

Method.

[Experimental]

The arrayBuffer() method of the `web.files.Blob` interface is
to read the contents of a Blob as binary data. It returns a promise
resolves with an `js.ArrayBuffer`.

`blob.arrayBuffer().then(function (buffer) {
// do something with buffer
});`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/arrayBuffer`
sourceraw docstring

constructorcljs

(constructor & args)

Constructor.

The Blob() constructor returns a new web.files.Blob object. The content of the blob consists of the concatenation of the values given in the parameter array.

array is an js.Array of js.ArrayBuffer, web.typed.ArrayBufferView, web.files.Blob, web.USVString objects, or a mix of any of such objects, that will be put inside the web.files.Blob. USVString are encoded as UTF-8. options is an optional BlobPropertyBag dictionary which may specify the following two attributes:

type, with a default value of "", that represents the MIME type of the content of the array that will be put in the blob. endings, with a default value of "transparent", that specifies how strings containing the line ending character \n are to be written out. It is one of the two values: "native", meaning that line ending characters are changed to match host OS filesystem convention, or "transparent", meaning that endings are stored in the blob without change.

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/Blob

Constructor.

The Blob() constructor returns a new `web.files.Blob` object. The content of the blob consists of the concatenation of the values given in the parameter array.

array is an `js.Array` of `js.ArrayBuffer`, `web.typed.ArrayBufferView`, `web.files.Blob`, `web.USVString` objects, or a mix of any of such objects, that will be put inside the `web.files.Blob`. USVString are encoded as UTF-8.
options is an optional BlobPropertyBag dictionary which may specify the following two attributes:

type, with a default value of \"\", that represents the MIME type of the content of the array that will be put in the blob.
endings, with a default value of \"transparent\", that specifies how strings containing the line ending character \\n are to be written out. It is one of the two values: \"native\", meaning that line ending characters are changed to match host OS filesystem convention, or \"transparent\", meaning that endings are stored in the blob without change.

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/Blob`
sourceraw docstring

sizecljs

(size this)

Property.

[Read Only]

The Blob.size property returns the size in bytes of the web.files.Blob a web.files.File.

var sizeInBytes = blob.size

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/size

Property.

[Read Only]

The Blob.size property returns the size in bytes of the `web.files.Blob`
a `web.files.File`.

`var sizeInBytes = blob.size`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/size`
sourceraw docstring

slicecljs

(slice this & args)

Method.

The Blob.slice() method is used to create a new web.files.Blob containing the data in the specified range of bytes of the source

var blob = instanceOfBlob.slice([start [, end [, contentType]]]);

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/slice

Method.

The Blob.slice() method is used to create a new `web.files.Blob`
containing the data in the specified range of bytes of the source

`var blob = instanceOfBlob.slice([start [, end [, contentType]]]);`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/slice`
sourceraw docstring

streamcljs

(stream this)

Method.

[Experimental]

The stream() method of the web.files.Blob interface transforms Blob into a web.files.ReadableStream of its data.

var stream = blob.stream();

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/stream

Method.

[Experimental]

The stream() method of the `web.files.Blob` interface transforms
Blob into a `web.files.ReadableStream` of its data.

`var stream = blob.stream();`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/stream`
sourceraw docstring

textcljs

(text this & args)

Method.

[Experimental]

blob.text().then(function (text) { // do something with the text });

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/text

Method.

[Experimental]

`blob.text().then(function (text) {
// do something with the text
});`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/text`
sourceraw docstring

typecljs

(type this)

Property.

[Read Only]

The type property of a web.files.Blob object provides the MIME of the file. It returns an empty string if the type couldn't

var mimetype = instanceOfFile.type

See also: https://developer.mozilla.org/en-US/docs/Web/API/Blob/type

Property.

[Read Only]

The type property of a `web.files.Blob` object provides the MIME
of the file. It returns an empty string if the type couldn't

`var mimetype = instanceOfFile.type`

See also: `https://developer.mozilla.org/en-US/docs/Web/API/Blob/type`
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close