stream method

Stream<Uint8List> stream()

Returns a Stream that can be used to read the contents of the Blob.

MDN Reference

Implementation

Stream<Uint8List> stream() async* {
  final bytes = _storage.$2;
  if (bytes != null) {
    yield bytes;
    return;
  }

  final buffer = await arrayBuffer();
  yield buffer.asUint8List();
}