writeKeyStream method

Future<void> writeKeyStream(
  1. Stream<String> stream
)

Writes a key from a stream of string parts, I feel bad for anyone that needs this.

Implementation

Future<void> writeKeyStream(Stream<String> stream) async {
  final comma = _startKey();
  await _writeRawString('${comma ? ',' : ''}"');
  await _writeRawStream(stream.map(_encodeStringContents));
  await _writeRawString('":');
}