Skip to main content

blob_bytes

Function blob_bytes 

Source
pub(crate) fn blob_bytes(
    it: &mut Interp,
    this: Value,
    _a: &[Value],
) -> Result<Value, Value>
Expand description

Blob.prototype.bytes()(ES2024/File API。丸ごと未対応だった)。 await blob.arrayBuffer() から new Uint8Array(...) する定番の2手間を 1メソッドで済ませる。arrayBuffer()と同じ内部バイト列を make_uint8array へそのまま渡す薄い実装。