bytes property

Future<List<int>> get bytes

Promise which resolves to the bytes with response body.

Implementation

Future<List<int>> get bytes => content!.then(
  (content) =>
      content is List<int> ? content : utf8.encode(content as String),
);