Skip to content

Blob

Types

blobPart

type blobPart = FileTypes.blobPart

blobPropertyBag

type blobPropertyBag = FileTypes.blobPropertyBag

Record fields

type_
option< string >
endings
option< endingType >

t

type t = FileTypes.blob = {size: int, type_: string}

Record fields

size
int
type_
string

Values

arrayBuffer

let arrayBuffer: t => promise<ArrayBuffer.t>

Parameters

t

Return type

promise< Stdlib.ArrayBuffer.t >

asBlob

let asBlob: t => t

Parameters

t

Return type

t

bytes

let bytes: t => promise<array<int>>

Parameters

t

Return type

promise< array< int > >

make

let make: (
~blobParts: array<blobPart>=?,
~options: blobPropertyBag=?,
) => t

Parameters

option< array< blobPart > > option< blobPropertyBag >

Return type

t

slice

let slice: (t, ~start: int=?, ~end: int=?, ~contentType: string=?) => t

Parameters

t option< int > option< int > option< string >

Return type

t

stream

let stream: t => ReadableStream.t<array<int>>

Parameters

t

Return type

ReadableStream.t< array< int > >

text

let text: t => promise<string>

Parameters

t

Return type

promise< string >