Function gloo::file::futures::read_as_bytes

source ·
pub fn read_as_bytes(
    blob: &Blob
) -> impl Future<Output = Result<Vec<u8, Global>, FileReadError>>
Available on crate features file and futures only.
Expand description

Returns the contents of blob as a Vec<u8>.

Equivalent to async fn read_as_bytes(blob: &Blob) -> Result<Vec<u8>, FileReadError> but without borrowing the Blob fore the lifetime of the future.